Skip to content

Instantly share code, notes, and snippets.

View airstrike's full-sized avatar
🦀
0-to-1 founder building with Rust + AI

Andy Terra airstrike

🦀
0-to-1 founder building with Rust + AI
View GitHub Profile
@ihercowitz
ihercowitz / VisaVale.py
Created October 28, 2010 13:19
Script para obter o saldo do Visa Vale
import urllib2, urllib, sys
from BeautifulSoup import BeautifulSoup
import re
class VisaVale():
def get_visavale_informations(self,visa):
url = 'http://www.cbss.com.br/inst/convivencia/SaldoExtrato.jsp'
data = urllib.urlencode([('numeroCartao',visa),('primeiroAcesso','S')])
request = urllib2.Request(url)
@RichardBronosky
RichardBronosky / userprofiles.admin.py
Created May 10, 2011 14:54
Django admin field order by m2m (or FK) relationship
from django.contrib import admin
from django.contrib.auth.admin import UserAdmin
from django.contrib.auth.models import User
from userprofiles.models import UserProfile
class UserProfileInline(admin.StackedInline):
model = UserProfile
fk_name = 'user'
max_num = 1
@airstrike
airstrike / vimrc
Created January 12, 2012 12:32
my vimrc file
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" a lot of this was stolen from: http://amix.dk/vim/vimrc.html "
""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => VIM user interface
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Set 7 lines to the curors - when moving vertical..
set so=2
set wildmenu "Turn on WiLd menu
@jaddison
jaddison / gist:1943426
Created February 29, 2012 18:43
adding to the templates tags available by default - add to the top of settings.py for example
from django.template.loader import add_to_builtins
add_to_builtins('django.contrib.staticfiles.templatetags.staticfiles')
add_to_builtins('django.templatetags.i18n')
add_to_builtins('django.templatetags.future')
@airstrike
airstrike / github.vim
Created May 22, 2012 18:00
Github-like color theme for vim. It's based on http://www.vim.org/scripts/script.php?script_id=2855 with fixes for .py files.
" Vim color file
"
" Author: André Terra <andreterra+nospam@gmail.com>
"
" Note: Anthony Carapetis original version of github's syntax thmee
" with a few changes, like better .py highlighting and line #s.
" Used Brian Mock's darkspectrum as a starting point/template
" Thanks to Ryan Heath for an easy list of some of the colours:
" http://rpheath.com/posts/356-github-theme-for-syntax-gem
@slig
slig / admonition.py
Created August 27, 2012 11:35
admonitions extension for python-markdown
import re
import markdown
from markdown.util import etree
class AdmonitionExtension(markdown.Extension):
def extendMarkdown(self, md, md_globals):
md.registerExtension(self)
@airstrike
airstrike / GetUserInfo.bas
Created January 2, 2014 17:20
Helper functions for fetching user information from the system/environment/network.
Private Type ExtendedUserInfo
EUI_name As Long
EUI_password As Long ' Null, only settable
EUI_password_age As Long
EUI_priv As Long
EUI_home_dir As Long
EUI_comment As Long
EUI_flags As Long
EUI_script_path As Long
EUI_auth_flags As Long
@airstrike
airstrike / anne.ahk
Created July 25, 2018 20:56
Anne Pro AutoHotkey (AHK) Script
SetCapsLockState, AlwaysOff
; The above lets you use hotkeys at the bottom end of the file on keyboards other than Anne and emulate the Fn Caps behavior
Menu, Tray, Icon, %A_WorkingDir%\anne.ico,, 1
<+J::Send, +{Left}
<+K::Send, +{Down}
<+L::Send, +{Right}
<+I::Send, +{Up}
<+#J::Send, +#{Left}
@airstrike
airstrike / autoexec.cfg
Last active February 26, 2020 00:29
CS:GO autoexec script
cl_crosshairsize 1; cl_crosshairgap 1; cl_crosshairthickness 0; cl_crosshaircolor 1; cl_crosshaircolor_b 250; cl_crosshaircolor_g 250; cl_crosshaircolor_r 250; cl_crosshairdot 1; cl_crosshairstyle 5; cl_crosshairalpha 250; cl_crosshairgap_useweaponvalue 0; cl_crosshairusealpha 1; cl_crosshair_drawoutline 0; cl_crosshair_sniper_width 1;
viewmodel_fov 68; viewmodel_offset_x 2.5; viewmodel_offset_y 0; viewmodel_offset_z -1.5; viewmodel_presetpos 3; cl_viewmodel_shift_left_amt 1.5; cl_viewmodel_shift_right_amt 0.75; viewmodel_recoil 0; cl_righthand 1;
alias "m4/ak47" "buy m4a1; buy ak47"
alias "aug/sg556" "buy aug; buy sg556"
alias "galilar/famas" "buy galilar; buy famas"
alias "g3sg1/scar20" "buy g3sg1; buy scar20"
alias "vesthelm/vest" "buy vesthelm; buy vest"
alias "vest" "buy vest"
@airstrike
airstrike / .vimrc
Last active October 13, 2020 03:39
Latest vimrc file (2019)
" VIM user interface
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
set so=2 " Show at least 2 lines around cursors when moving vertically
set ruler "Always show current position
set cmdheight=1 "The commandbar height
" Set backspace config
set backspace=eol,start,indent
set whichwrap+=<,>,h,l