Skip to content

Instantly share code, notes, and snippets.

View aaronjanse's full-sized avatar

Aaron Janse aaronjanse

  • Berkeley, CA
View GitHub Profile

Keybase proof

I hereby claim:

  • I am aaronduino on github.
  • I am aaronjanse (https://keybase.io/aaronjanse) on keybase.
  • I have a public key ASBem7Vx9_aAoQlepr-BE9ehqPKTg6Lea5cFPrzSCg39-go

To claim this, I am signing this object:

@aaronjanse
aaronjanse / fix.sh
Created August 21, 2017 14:37
Magical command to make gpg work with YubiKey smartcard
killall gpg-agent && gpg-agent --daemon --use-standard-socket --pinentry-program /usr/local/bin/pinentry
@aaronjanse
aaronjanse / burschcleaner.user.js
Last active September 27, 2016 22:20
Bursch Blog Cleaner
// ==UserScript==
// @name Bursch Blog Cleaner
// @version 1.0
// @description This makes Mr.Bursch's blog legible!
// @author Aaron Janse
// @match http://mrbursch.blogspot.com/*
// @grant none
// ==/UserScript==
(function() {
@aaronjanse
aaronjanse / anglediff.js
Created June 20, 2016 21:42
find the smallest distance between two angles
// from http://stackoverflow.com/a/7869457
// converted to js code
// x and y are the angles in radians
function getDifference(x, y) {
var a = x-y;
a = (function(i, j) {return i-Math.floor(i/j)*j})(a+Math.PI, Math.PI*2); // (a+180) % 360; this ensures the correct sign
a -= Math.PI;
return a;
}