This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# setup rpi wifi | |
sudo killall wpa_supplicant dhcpcd >/dev/null 2>&1 | |
sleep 2 | |
echo "logging into eduroam..." | |
wpa_supplicant -i wlp2s0 -B -c /etc/wpa_supplicant/wpa_supplicant.conf | |
sleep 1 | |
echo -en "\r[* ]" | |
sleep 1 | |
echo -en "\r[** ]" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
while [ true ] | |
do | |
echo "starting socks5 proxy at localhost:22222" | |
ssh -A -ND localhost:22222 metrics@bastion.prodnext.ottoq.com -v & | |
LASTPID=$! | |
ALIVE=true | |
while [ $ALIVE = true ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PIL import Image, ImageFilter | |
import os | |
import sys | |
import random | |
import math | |
def main(): | |
if len(sys.argv) <= 1: | |
print "USAGE: python spritegen.py <image/dir>" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"bytes" | |
"log" | |
"net/smtp" | |
"text/template" | |
) | |
func main() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"bytes" | |
"encoding/json" | |
"fmt" | |
"reflect" | |
"sort" | |
"strconv" | |
"time" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
fl=$(ls -tdr1 ~/Downloads/* | -tail -1) | |
echo $fl | |
mv "$fl" ./ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sc [8] = gc [64]= | |
0 block 0[8] | |
1 ----*\ block 1[8] | |
1 \---> block 2[8] | |
1 block 3[8] | |
. ... | |
. ... | |
. ... | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "building for raspi..." | |
GOOS=linux GOARCH=arm GOARM=7 go build . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
commithash=$(git rev-parse --verify HEAD) | |
GOOS=linux go build -ldflags "-X main.commithash=$commithash" . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"flag" | |
) | |
var ( | |
commithash string | |
versionFlag = flag.Bool("v", false, "git commit hash") | |
) |
OlderNewer