Skip to content

Instantly share code, notes, and snippets.

View stattrak-dragonlore's full-sized avatar

patrick stattrak-dragonlore

View GitHub Profile
@stattrak-dragonlore
stattrak-dragonlore / my_template_for_cpc_game
Created October 19, 2014 11:59
cpp template for programming contest
#include <sstream> <numeric> <functional>
hash_map:
vc2005:
using namespace stdext;
#include <hash_map>
gcc:
#include <ext/hash_map>
using namespace __gnu_cxx;
struct str_hash
# nginx server as a proxy
server {
listen 8888;
location / {
proxy_pass http://$http_host$request_uri;
}
resolver 8.8.8.8;
@stattrak-dragonlore
stattrak-dragonlore / private.xml
Created April 19, 2013 03:18
My private.xml for KeyRemap4MacBook dota key remap and command_r to option_r
<?xml version="1.0"?>
<root>
<appdef>
<appname>WARCRAFTIII</appname>
<equal>com.blizzard.WarcraftIII</equal>
</appdef>
<item>
<name>My custom keys for Dota items</name>
<only>WARCRAFTIII</only>
<identifier>private.dota_keyboard_remap_1</identifier>
diff --git a/autossh.c b/autossh.c
--- a/autossh.c
+++ b/autossh.c
@@ -104,7 +104,7 @@
#define NO_RD_SOCK -2 /* magic flag for echo: no read socket */
-#define OPTION_STRING "M:V1246ab:c:e:fgi:kl:m:no:p:qstvw:xyACD:F:I:MKL:NO:PR:S:TVXY"
+#define OPTION_STRING "M:V1246ab:c:e:fgi:kl:m:no:p:qstvw:xyACD:F:I:MKL:NO:PR:S:TVXYZ"
@stattrak-dragonlore
stattrak-dragonlore / OS X reinstall check list
Last active December 10, 2015 02:58
Mac OS X reinstall check list
* Google Chrome
* Software Update
* Terminal
~/Library/Preferences/com.apple.Terminal.plist
* dotfiles
//
// Keychain.h
// OpenStack
//
// Based on KeychainWrapper in BadassVNC by Dylan Barrie
//
// Created by Mike Mayo on 10/1/10.
// The OpenStack project is provided under the Apache 2.0 license.
//
// http://overhrd.com/?p=208
@stattrak-dragonlore
stattrak-dragonlore / meet-in-the-middle.py
Created January 4, 2012 12:41
demo of meet-in-the-middle attack (32bit)
# http://www.nruns.com/_downloads/advisory28122011.pdf
# http://bugs.python.org/issue13703
import sys
import string
import itertools
# hash function used by python string object
def hash(s):
slen = len(s)
@stattrak-dragonlore
stattrak-dragonlore / w3g_format.txt
Created September 1, 2011 05:37
WarCraft III Replay file format description
*******************************************************************************
* WarCraft III Replay file format description *
* *
* document version: 1.18 *
* document date : 2007-06-26 *
* document authors: blue, nagger *
* *
* For more informtion about w3g file format, please visit: *
* http://w3g.deepnode.de *
* *
set showcmd
set nu
syntax on
set autoindent
set smartindent
color torte
set hlsearch
set ts=4
set expandtab
set shiftwidth=4
@stattrak-dragonlore
stattrak-dragonlore / about.md
Created August 11, 2011 06:37 — forked from jasonrudolph/about.md
Programming Achievements: How to Level Up as a Developer