I hereby claim:
- I am kbingham on github.
- I am kbingham (https://keybase.io/kbingham) on keybase.
- I have a public key whose fingerprint is A8AF ECF8 ECE5 5165 047E BB96 2386 3DC3 831D B2B1
To claim this, I am signing this object:
# Kierans Generic Makefile | |
# www.kieranbingham.co.uk | |
# Default to build with multiple instances for speed | |
MAKEFLAGS =+ -j | |
# Beware, This will create this application | |
# binary based on the current directory name. | |
TARGET := $(shell basename `pwd`) |
#!/bin/sh | |
launchonce() { | |
app=`basename $1` | |
pidof $app >/dev/null && echo "$app is already running" || $1 & | |
} | |
launchonce_alt() { | |
pidof $2 >/dev/null && echo "$1 is already running" || $1 & | |
} |
#These directories may be excluded: | |
# contains mounted file systems | |
.gvfs | |
.local/share/gvfs-metadata | |
# contains the actual encrypted home directory | |
.Private | |
# session-specific | |
.dbus | |
.cache |
#!/bin/sh | |
### WIMIP | |
### A helper script to easily report both local and public IP addresses of a device on commandline | |
### Kieran Bingham 2015 | |
### www.kieranbingham.co.uk | |
IFACE=`route -n | grep ^0.0.0.0 | awk '{ print $8 }'` |
// Remove all I2C Device Tables, when there is an OF table present | |
// | |
// Aim to rename the probe function, and adapt its prototype, if: | |
// - The driver supports an OF table already | |
// - The driver is not currently using the 'id' variable in the probe | |
// | |
// First identify that we are in a suitable file, and assumptions met | |
// |
I hereby claim:
To claim this, I am signing this object:
#!/bin/sh | |
FILENAME=screen_$(date +%Y%m%d_%H%M%S).png | |
echo "Attempting capture to $FILENAME" | |
adb shell screencap -p | sed 's/\r$//' > "$FILENAME" |
My simple wordpress blogs run on heroku. Why? Because its free. | |
However, I recently got an e-mail from heroku informing me that I needed to upgrade from cedar-10 (based on ubuntu-10.04 LTS) to cedar-14 (based on ... ubuntu-14.04 LTS). | |
This seemed like a reasonable thing to do, and so I jumped in and executed the following as requested: | |
$ heroku stack:set cedar-14 | |
$ git commit --allow-empty -m "Upgrading to Cedar-14" | |
$ git push heroku master |
#!/bin/bash | |
# dmesg-diff | |
# Kieran Bingham 2016 | |
# Public Domain | |
# | |
# Strip out Linux Kernel timestamps when performing a diff on two dmesg files | |
# | |
# Initial version as proof-of-concept, but already useful. | |
# This could be extended to parse extra flags for diff for example |
#!/bin/bash | |
## Derived from : http://stackoverflow.com/questions/2108405/branch-descriptions-in-git | |
## answered May 23 '13 at 9:21 ## jsageryd | |
# Shows branches with bases | |
function gb() { | |
branches=$(git for-each-ref --format='%(refname)' refs/heads/ | sed 's|refs/heads/||') | |
head=$(git rev-parse --abbrev-ref HEAD) | |
for branch in $branches; do |