Skip to content

Instantly share code, notes, and snippets.

View stqism's full-sized avatar

Sean Qureshi stqism

View GitHub Profile
Verifying my Blockstack ID is secured with the address 15XTs4FcNVwv3RnHEqVnetsXPDSxuEwseC https://explorer.blockstack.org/address/15XTs4FcNVwv3RnHEqVnetsXPDSxuEwseC
@stqism
stqism / designer.html
Last active August 29, 2015 14:15
designer
<link rel="import" href="../notification-elements/notification-alert.html">
<link rel="import" href="../topeka-elements/category-images.html">
<link rel="import" href="../core-icon/core-icon.html">
<link rel="import" href="../topeka-elements/theme.html">
<link rel="import" href="../topeka-elements/topeka-resources.html">
<link rel="import" href="../topeka-elements/topeka-app.html">
<polymer-element name="my-element">
<template>
@stqism
stqism / 1.py
Last active August 29, 2015 14:02
Holy fuck Python is slow
count = 0
while (count < 1000000000):
count = count + 1
@stqism
stqism / dns2sign.sh
Last active August 29, 2015 13:57
Tox DNS Discovery scripts
#!/usr/bin/env sh
#Compile other/fun/sign.c from ProjectTox-Core and put it here named sign
#generate a keypair with ./sign g
#sh dns2key.sh v=tox1;etc {signing key}
DNS=$1
TOXVER=`echo -n $DNS | tr ';:"\\\/' '\n' | grep tox | tr '=' ' ' | awk '{print $NF}'`
case $TOXVER in
tox1)
### Keybase proof
I hereby claim:
* I am stqism on github.
* I am sean (https://keybase.io/sean) on keybase.
* I have a public key whose fingerprint is 4971 62AE FF87 64E3 935D A908 13D2 0431 69D2 5DF4
To claim this, I am signing this object:
### Keybase proof
I hereby claim:
* I am stqism on github.
* I am stqism (https://keybase.io/stqism) on keybase.
* I have a public key whose fingerprint is 7C5F 2B56 FC2F FDD0 57D4 381F 6EDD CAA7 CD5A E9CD
To claim this, I am signing this object:
__asm__ (goto("1:"
STATIC_KEY_INITIAL_NOP
".pushsection __jump_table, \"aw\" \n\t"
_ASM_ALIGN "\n\t"
_ASM_PTR "1b, %l[l_yes], %c0 \n\t"
".popsection \n\t"
: : "i" (key) : : l_yes););
@stqism
stqism / color.def.h
Created September 2, 2013 13:13
Turning a list of hex values in to curses color defines, powered by python. Note: This is an absolutely horrible thing to do
#define COLOR_B0171F 0
#define COLOR_DC143C 1
#define COLOR_FFB6C1 2
#define COLOR_FFAEB9 3
#define COLOR_EEA2AD 4
#define COLOR_CD8C95 5
#define COLOR_8B5F65 6
#define COLOR_FFC0CB 7
#define COLOR_FFB5C5 8
#define COLOR_EEA9B8 9
l = 0
cdefine = ''
cint = ''
with open("color.def.src") as f:
for line in f:
n = 2
hex = [line[i:i+n] for i in range(0, len(line), n)]
val1 = str(int(hex[0],16) * 3.90625).split('.', 1)[0]
val2 = str(int(hex[1],16) * 3.90625).split('.', 1)[0]
val3 = str(int(hex[2],16) * 3.90625).split('.', 1)[0]
#define COLOR_000000 0
#define COLOR_800000 1
#define COLOR_008000 2
#define COLOR_808000 3
#define COLOR_000080 4
#define COLOR_800080 5
#define COLOR_008080 6
#define COLOR_C0C0C0 7
#define COLOR_808080 8
#define COLOR_FF0000 9