Skip to content

Instantly share code, notes, and snippets.

View kaneoriley's full-sized avatar

Kane O'Riley kaneoriley

View GitHub Profile
@kaneoriley
kaneoriley / hubottest
Created July 9, 2017 06:34 — forked from coderofsalvation/hubottest
commandline wrapper script to invoke hubot commands from the commandline (handy for testing while developing) using expect
#!/usr/bin/expect -f
# usage: ./hubottest "hubot help"
spawn bin/hubot.coffee
sleep 3
expect "Hubot>"
send "hubot [lrange $argv 0 10]\n"
expect eof
@kaneoriley
kaneoriley / BetterBounceInterpolator.java
Created January 19, 2017 23:59 — forked from Kraiden/BetterBounceInterpolator.java
A more configurable bounce interpolator for Android animations
import android.view.animation.Interpolator;
import static java.lang.Math.*;
public class BetterBounceInterpolator implements Interpolator {
private int mBounces;
private double mEnergy;
/** Have more control over how to bounce your values.
*
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- google's material design colours from
http://www.google.com/design/spec/style/color.html#color-ui-color-palette -->
<!--reds-->
<color name="md_red_50">#FFEBEE</color>
<color name="md_red_100">#FFCDD2</color>
<color name="md_red_200">#EF9A9A</color>