Skip to content

Instantly share code, notes, and snippets.

View aspiers's full-sized avatar

Adam Spiers aspiers

View GitHub Profile
# Fix bash's utterly moronic defaults for completion by adding these to your ~/.inputrc
set bell-style visible
set show-all-if-ambiguous on
set show-all-if-unmodified on
Moved to https://github.com/aspiers/SUSE-dist/blob/master/bin/check-chef-client-drift
@aspiers
aspiers / forward-word-backtrace-2.md
Last active November 16, 2015 13:11
even WEIRDER backtrace from forward-word on emacs 24.5

See https://gist.github.com/aspiers/7330084c7bd99d2003e2 for the previous one related to ido-ubiquitous. After deinstalling ido-ubiquitous, forward-word still fails! How to debug this?!

Debugger entered--Lisp error: (void-function nil)
  nil(144 192)
  forward-word(1)
  call-interactively(forward-word nil nil)
  command-execute(forward-word)
@aspiers
aspiers / forward-word-backtrace.md
Last active November 16, 2015 11:54
weird backtrace from forward-word on emacs 24.5
Debugger entered--Lisp error: (void-function nil)
  nil(81 192)
  forward-word(1)
  #<subr call-interactively>(forward-word nil nil)
  ad-Advice-call-interactively(#<subr call-interactively> forward-word nil nil)
  apply(ad-Advice-call-interactively #<subr call-interactively> (forward-word nil nil))
  call-interactively(forward-word nil nil)
  command-execute(forward-word)
@aspiers
aspiers / gist:724919a8a4eb4a07cf1d
Created November 1, 2015 13:48
backward-word fails?!
Debugger entered--Lisp error: (void-function nil)
nil(1027 1)
backward-word(1)
call-interactively(backward-word nil nil)
command-execute(backward-word)
@aspiers
aspiers / gist:855c1c815a41519f0241
Created November 1, 2015 13:44
bizarre stack trace from autoload
Debugger entered--Lisp error: (void-function nil)
indirect-function(nil)
help-function-arglist(nil preserve-names)
ad-arglist(nil)
ad-make-advised-definition(er/expand-region)
ad-activate-advised-definition(er/expand-region nil)
ad-activate-internal(er/expand-region)
ad--defalias-fset(nil er/expand-region (autoload "expand-region" nil nil nil))
apply(ad--defalias-fset nil (er/expand-region (autoload "expand-region" nil nil nil)))
#[128 "\300\301\302#\207" [apply ad--defalias-fset nil nil] 5 nil](er/expand-region (autoload "expand-region" nil nil nil))
@admin
Feature: crowbar batch subcommand
As a cloud administrator
I want to use the crowbar batch command
In order to capture cloud configuration and do unattended configuration
Background:
Given the admin node responds to a ping
And I can establish SSH connection
And I can reach the crowbar API
#!/bin/bash
if [[ $# -ne 1 ]]
then
echo "Usage: ${0} path/to/clone"
exit 1
else
dir=${1}
fi
@aspiers
aspiers / gist:cbff7c41ac2998265989
Created January 3, 2015 16:57
onename id proof
Verifying that +aspiers is my openname (Bitcoin username). https://onename.io/aspiers
@aspiers
aspiers / MSP-sqlite3.sh
Last active August 29, 2015 14:11
run SQL on MobileSheetsPro SQLite database
#!/bin/bash
#
# Handy script to allow surgery on MobileSheetsPro SQLite database
# from host computer via adb. This means you can use the full history
# and CLI features of a feature-complete modern shell, rather than
# the crippled crap which Android's "adb shell" gives you.
#
# Example:
#
# MSP-sqlite3.sh 'select * from Songs where Title like "%Foo%"'