I hereby claim:
- I am starkers on github.
- I am starkers (https://keybase.io/starkers) on keybase.
- I have a public key ASBV3p_1ysgoIbzTE1O_F6S6Z7k365WlK9d_fdby9v1k4Qo
To claim this, I am signing this object:
#!/usr/bin/env bash | |
set -o nounset # Treat unset variables as an error | |
# | |
# you can call this script as such if needed: | |
# ./grants --user="mymysqlusername" --pass="password" --host="somehost" | |
# | |
# I much prefer .my.cnf or similar |
I hereby claim:
To claim this, I am signing this object:
#!/usr/bin/env bash | |
## This rar's a file up with a password and emails it | |
## not as good as using openssl to encrypt but I'm not about to explain openssl pipes to my users | |
# rar does the job :/ | |
FILE=/var/log/some_logfile.log | |
PASS="your super top secret password" |
#!/usr/bin/env bash | |
# quickly backs up a wordpress install for you, just specify the wordpress install path | |
ConfFile="$1/wp-config.php" | |
if [ "X$1" == "X" ]; then | |
echo ".. quickly backs up a wordpress database for you, just specify the wordpress install path" |
# I wanted a dead simple reminder if I'm in a git managed directory | |
# This takes the standard ubuntu $PS1 and adds (branch-name) in "default" terminal colour just before your $ / # | |
# | |
# the correct way on centos is to add it to something like /etc/sysconfig/bash-prompt-{xterm,default,screen} | |
# I can't be arsenaled... -david@starkers.org | |
# | |
# centos6: add to /etc/bashrc | |
# ubuntu14/mint: add to /etc/bash.bashrc | |
# vim:ts=2:sw=2 |
#!/usr/bin/env bash | |
ENV="$(env)" | |
if ! grep -q DISPLAY= <<<"$ENV" ; then | |
echo dunno what your DISPLAY= is, setting default and crossing fingers | |
export DISPLAY=:0 | |
fi | |
# simple script that watches for a Yubikey being plugged in.. | |
# |
#!/usr/bin/env bash | |
#set -x | |
# Prune and volumes older than 2 months: | |
PAST=`date --date='-2 months 0 day ago' +%Y-%m-%d` | |
#EG a hard coded date | |
#PAST="2012-11-29" | |
#PAST="2013-11-29" |
#!/usr/bin/env bash | |
# | |
# simple templating script for Generating CSR's -david@starkers.org 121001 | |
# .. this relies on having openssl availble in your path .. | |
# Its not elegant but its easy to use.. | |
# | |
# TODO: too much ugly wraping of whitespace into openssl commands | |
# (there is another way but I forgot and this works) | |
# This program is free software. It comes without any warranty, to |
#!/usr/bin/env bash | |
# This script loops forever and waits for a standard STDIN for each loop. | |
# | |
# When you hit [RETURN] it pipes you're input into the command you launched the script with | |
# | |
# For example.. If I want to compare public DNS records (on 4.2.2.3 for example) with the | |
# records on my own DNS server.. EG: 1.2.3.4 I would split a terminator it two and run: | |
# Terminal 1: doorman dig @4.2.2.3 +short | |
# Terminal 2: doorman dig @1.2.3.4 +short |
#!/usr/bin/env bash | |
# any2mp3 | |
# Converts to mp3 anything mplayer can play | |
# requires: mplayer and lame | |
# Also ensure you have space to dump the .wav | |
TMP=audiodump-`date +%s`.wav | |
[ "$1" ] || { echo "Usage: $0 file1.wma file2.mp4"; exit 1; } |