Skip to content

Instantly share code, notes, and snippets.

@devsli
devsli / Clicker Heroes.au3
Last active August 29, 2015 14:10
Clicker Heroes rapid clicker. http://clickerheroes.com
; [1] Useless
; [2] 2xDPS
; [3] 1,5xCritClick
; [4] 2xGold
; [5] 1%Gold/Click
; [6] Dark Ritual
; [7] 3xClick
; [8] Double next
; [9] Reload prev
@devsli
devsli / flooder.c
Last active August 29, 2015 14:06
Client-server flood generator
#include <assert.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <string.h>
#include <sys/types.h>
@devsli
devsli / calc.c
Last active April 2, 2016 17:45
Simple function ptr
// $ a.out 1 "+" 2
// 3
// $ a.out 2 "*" 3
// 6
// $ a.out 6 "/" 2
// 3
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
@devsli
devsli / site-permissions.sh
Last active August 29, 2015 14:06
Recursive site permissions set
#!/bin/sh
if [ "$1" = "" ]; then
echo "usage: $0 website-dir";
echo;
# echo "Set owner of <website-dir> to www:nogroup,";
echo "Set permissions rw-r-r for regular files";
echo "and rwx-rx-rx for directories";
echo;
echo "Root permissions might be required.";
@devsli
devsli / unbound-parent-method.py
Last active August 29, 2015 14:01
Invoke unbound method
class A(object):
def __init__(self):
self.name = 'Andy'
def tell(what):
def inner(self):
print(" -- %s, %s!" % (what, self.name))
return inner
hi = tell("Hello")