Skip to content

Instantly share code, notes, and snippets.

@jaqque
jaqque / gist:1542104
Created December 30, 2011 23:52
brew install -v feh
==> Installing feh dependency: imlib2
==> Downloading http://downloads.sourceforge.net/project/enlightenment/imlib2-src/1.4.4/imlib2-1.4.4.tar.bz2
File already downloaded in /Users/jhriv/Library/Caches/Homebrew
/usr/bin/tar xf /Users/jhriv/Library/Caches/Homebrew/imlib2-1.4.4.tar.bz2
==> Patching
/usr/bin/patch -f -p1 -i 001-homebrew.diff
patching file src/modules/loaders/loader_png.c
==> ./configure --disable-dependency-tracking --prefix=/usr/local/Cellar/imlib2/1.4.4 --enable-amd64=no
./configure --disable-dependency-tracking --prefix=/usr/local/Cellar/imlib2/1.4.4 --enable-amd64=no
checking build system type... x86_64-apple-darwin11.2.0
@jaqque
jaqque / git-undress.sh
Created December 14, 2012 20:30
git subcommand to convert a regular repository to a bare repository, suitable for pushing to
#!/bin/sh
source="$PWD"
target="$PWD.git"
# verify we are a git repositoy
if [ ! -d "$source/.git" ]; then
echo 'No git repository found.' 1>&2
exit 1
fi
for i in `aptitude -F %p search '~i!~E!~M'`; do echo; echo --- $i ---; echo;yes n | sudo aptitude --purge markauto $i; done
@jaqque
jaqque / prompt_timing.zsh
Created June 12, 2013 16:12
Timing prompt expansions
#!/bin/zsh
export TESTS=${TESTS:-1000000}
# liberated from liquidprompt
local ti_sgr0="$( { tput sgr0 || tput me ; } 2>/dev/null )"
local ti_bold="$( { tput bold || tput md ; } 2>/dev/null )"
if tput setaf >/dev/null 2>&1 ; then
ti_setaf () { tput setaf "$1" ; }
elif tput AF >/dev/null 2>&1 ; then
@jaqque
jaqque / qls
Created July 29, 2013 20:47
quick ls
qls() { perl -E'for(@ARGV){-d||next;say"$_:";opendir$d,$_;say+join"\n",sort(readdir$d)}' "${@:-.}"; }
@jaqque
jaqque / fixpath
Created September 10, 2013 20:08
bash shell function to clean up a PATH, and append . (complete with love note) Would probably work under zsh, even if $path would be cleaner.
fixpath () {
local IFS=:
local newpath=''
for i in $PATH; do
[[ -d "$i" && "$i" != '.' ]] && newpath="$newpath${newpath:+:}$i"
done
PATH="$newpath:/this_could_be_dangerous/:."
}
fixpath
default.rb:
salt_data = 'this is ridiculous'
ruby_block 'fetch-salt-data' do
block do
salt_data = File.read(wp_secrets)
puts "Hay! Look! Salt_data!"
puts "#{salt_data}"
end
action :create
@jaqque
jaqque / runme.sh
Last active December 26, 2015 04:09
4-way videos
#!/bin/zsh
typeset -a vid win opts
vid=(
"After Effects- DNA Strand.mp4"
"HD LAVA LAMP Ambient Video Wall Art -- 30 Minute Relaxing Ambient Video Clip.mp4"
"Crawling Neutrophil Chasing a Bacterium.mp4"
"ekg flatline.mp4"
)
@jaqque
jaqque / gist:7649174
Last active December 29, 2015 09:19
Ogre Unboxing!
Ogre party at my house!
Saturday, November 30, 2013. 1 PM.
On the menu is Ogre and Pot Luck!
Please RSVP.

Keybase proof

I hereby claim:

  • I am jaqque on github.
  • I am jaqque (https://keybase.io/jaqque) on keybase.
  • I have a public key whose fingerprint is D8C6 4C2C E88E E5CF 8737 16C4 ADE9 4F65 0779 9E74

To claim this, I am signing this object: