Skip to content

Instantly share code, notes, and snippets.

View kaihendry's full-sized avatar

Kai Hendry kaihendry

View GitHub Profile
@jorinvo
jorinvo / challenge.md
Last active April 21, 2023 17:14
This is a little challenge to find out which tools programmers use to get their everyday tasks done quickly.

You got your hands on some data that was leaked from a social network and you want to help the poor people.

Luckily you know a government service to automatically block a list of credit cards.

The service is a little old school though and you have to upload a CSV file in the exact format. The upload fails if the CSV file contains invalid data.

The CSV files should have two columns, Name and Credit Card. Also, it must be named after the following pattern:

YYYYMMDD.csv.

#GoPro HERO4 Black Wifi Hacking, ep 2

By Maelstrom Napalm, @odwdinc and Konrad Iturbe

###Status URL:

http://10.5.5.9/gp/gpControl/status

####Protune EV compensation: Value | URL

@tomfuertes
tomfuertes / make-website.sh
Last active August 26, 2022 21:54
create an s3 bucket, config website serving, create cloudfront distribution, sync local dir
#!/usr/bin/env bash
# To run:
# $ brew uninstall s3cmd && brew install s3cmd --HEAD
# $ s3cmd --configure # fill in w/ amazon account vars
# $ cd path/to/local/static/site
# $ wget https://gist.githubusercontent.com/tomfuertes/9175005/raw/make-website.sh
# $ bash make-website.sh
#
# NOTE: cfcreate takes ~15 minutes to run on AWS.
@NickSto
NickSto / gist:6920790
Last active July 11, 2017 15:44 — forked from rnorth/gist:2031652
Cookie-based authentication with nginx
worker_processes 1;
error_log logs/error.log;
events {
worker_connections 1024;
}
@ElectronicRU
ElectronicRU / dmenu_history.sh
Last active December 14, 2015 19:48
dmenu script for providing unlimited history sorted by number of uses/most recent use.
#!/bin/sh
if [ $# -lt 1 ] ; then
echo 1>&2 "usage: dmenu_history hist_file dmenu_opts..."
exit 1
fi
f="$1"
tf=`mktemp`
if ! [ -e "$f" ]; then touch "$f"; fi
shift
( sort -r -k 1,1 -n -s "$f" | cut -d' ' -f2- ; cat - ) | dmenu "$@" |
@kaihendry
kaihendry / gist:3170423
Created July 24, 2012 14:53
This works well
x220:/srv/www/greptweet$ cat foo.cgi
#!/bin/bash
exec 2>&1
cat <<END
Cache-Control: no-cache
Content-Type: text/html
END
./foo-script.sh & disown
@btoone
btoone / curl.md
Last active April 2, 2024 20:18
A curl tutorial using GitHub's API

Introduction

An introduction to curl using GitHub's API.

The Basics

Makes a basic GET request to the specifed URI

curl https://api.github.com/users/caspyin