Skip to content

Instantly share code, notes, and snippets.

View AustinDizzy's full-sized avatar
🐘
workin' on it

Austin Siford AustinDizzy

🐘
workin' on it
View GitHub Profile
#define SLJIT_CACHE_FLUSH(from, to) \
void jit_clear_cache(char* from, char *to)
{
const int syscall = 0xf0002;
__asm __volatile (
"mov r0, %0\n"
"mov r1, %1\n"
"mov r7, %2\n"
"mov r2, #0x0\n"
"svc 0x00000000\n"
#!/bin/bash
if [ -z "$1" ] || [ "$1" == "help" ] ; then
echo
echo "Usage: git check [remote]:[branch]"
echo
else
OPTS=(${1//:/ })
remote=${OPTS[0]}
branch=${OPTS[1]}

Keybase proof

I hereby claim:

  • I am AustinDizzy on github.
  • I am austindizzy (https://keybase.io/austindizzy) on keybase.
  • I have a public key whose fingerprint is 8CCC 05F7 2068 D9B3 877F 7944 9080 2BBF C328 0441

To claim this, I am signing this object:

@AustinDizzy
AustinDizzy / README.md
Created May 17, 2015 21:43
A small demonstration on xkcd #1335's time data collection.

xkcd-now

A small demonstration on xkcd #1335's time data collection.

Demo here.

preview

@AustinDizzy
AustinDizzy / pre-commit
Created July 12, 2015 04:47
A pre-commit git hook that prompts you to automatically `gofmt` Go files staged to commit.
#!/bin/sh
# Modified 2015, Austin Dizzy
# Copyright 2012 The Go Authors. All rights reserved.
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
# git gofmt pre-commit hook
#
# To use, store as .git/hooks/pre-commit inside your repository and make sure
# it has execute permissions.
@AustinDizzy
AustinDizzy / gist:7c4fdff0cdda5d8c504c
Last active February 10, 2018 09:34
a quick script that easily reads instagram DM structure and prints from data variable
var url = "https://instagram.com/api/v1/direct_share/inbox/";
$.getJSON(url, function(data){
for(var i = 0; i < data.shares.length; i++){
var post = data.shares[i];
console.log(post.caption.user.username + ": " + post.caption.text + "\nURL:" + post.image_versions[0].url+"\n");
for(var k = 0; k < post.comment_count; k++){
var comment = post.comments[k];
console.log("\t"+comment.user.username + ": " + comment.text + "\n");
}
console.log("========================\n");
@AustinDizzy
AustinDizzy / file.js
Created September 16, 2015 15:10
A simple javascript bookmarklet to automatically clean unwanted URLs from an IBM AppScan walkthrough during import.
function extractDomain(url) {
return url.split('/')[(url.indexOf("://") > -1) ? 2 : 0].split(':')[0];
}
function doIt(sites) {
var d = document.getElementsByClassName("admin_grid")[0].getElementsByTagName("tbody")[0];
for (var i = 0; i < d.children.length; i++) {
var checkbox = d.children[i].getElementsByTagName("input")[0],
url = d.children[i].getElementsByTagName("td")[1].innerText;
var allowed = sites;
for (var k = 0; k < sites.length; k++) {

Keybase proof

I hereby claim:

  • I am austindizzy on github.
  • I am abs (https://keybase.io/abs) on keybase.
  • I have a public key ASC4EOZR965HxHPw4Y3Ij-ne0dpI4-9pwyYpBEljtWCfkwo

To claim this, I am signing this object:

@AustinDizzy
AustinDizzy / main.go
Created May 16, 2018 19:36
bulk-sql-insert: just some quick script to bulk insert records into a sql database with some throttling and batching capabilities
package main
import (
"bytes"
"database/sql"
"flag"
"fmt"
"io/ioutil"
"log"
"os"