This document is still a scratch
You’ll want a directory to do this in so that you don’t screw up your machine.
| #!/bin/sh | |
| # | |
| # Import all SSH keys from LP | |
| # | |
| PREFIX=~ | |
| SSH_ASKPASS=$PREFIX/bin/lp-askpass.sh | |
| export SSH_ASKPASS | |
| # This is needed to force ssh-add to honor our SSH_ASKPASS. | |
| DISPLAY=foo | |
| export DISPLAY |
| # Extract archives - use: extract <file> | |
| # Based on http://dotfiles.org/~pseup/.bashrc | |
| function extract() { | |
| if [ -f "$1" ] ; then | |
| local filename=$(basename "$1") | |
| local foldername="${filename%%.*}" | |
| local fullpath=`perl -e 'use Cwd "abs_path";print abs_path(shift)' "$1"` | |
| local didfolderexist=false | |
| if [ -d "$foldername" ]; then | |
| didfolderexist=true |
| #compdef msfconsole | |
| # ------------------------------------------------------------------------------ | |
| # Copyright (c) 2014 Spencer McIntyre | |
| # All rights reserved. | |
| # | |
| # Redistribution and use in source and binary forms, with or without | |
| # modification, are permitted provided that the following conditions are met: | |
| # * Redistributions of source code must retain the above copyright | |
| # notice, this list of conditions and the following disclaimer. | |
| # * Redistributions in binary form must reproduce the above copyright |
| #!/bin/sh | |
| # Enable and disable HDMI output on the Raspberry Pi | |
| is_off () | |
| { | |
| tvservice -s | grep "TV is off" >/dev/null | |
| } | |
| case $1 in |
| #!/bin/sh | |
| # http://d.hatena.ne.jp/jeneshicc/20110215/1297778049 | |
| if [ -f $1 ] ; then | |
| case $1 in | |
| *.tar.bz2) tar xvjf $1 ;; | |
| *.tar.gz) tar xvzf $1 ;; | |
| *.tar.xz) tar xvJf $1 ;; | |
| *.bz2) bunzip2 $1 ;; |