diff options
author | Peter Palfrader <peter@palfrader.org> | 2007-07-26 07:19:04 +0000 |
---|---|---|
committer | weasel <weasel@bc3d92e2-beff-0310-a7cd-cc87d7ac0ede> | 2007-07-26 07:19:04 +0000 |
commit | 4afad74e62c7dc84e895854fb9cb218ca9d05f21 (patch) | |
tree | aadea9ef68b79bd5bd5acfc6605593d617760f0e /zshrc | |
parent | f1e3df81118c0c7c650c37dcf8af2474b894f38a (diff) |
add base64 stuff
git-svn-id: svn+ssh://asteria.noreply.org/svn/weaselutils/trunk@287 bc3d92e2-beff-0310-a7cd-cc87d7ac0ede
Diffstat (limited to 'zshrc')
-rw-r--r-- | zshrc | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -177,8 +177,11 @@ fi alias 221='pstops "2:0L@.7(21cm,0)+1L@.7(21cm,14.85cm)"' alias rot13='tr a-zA-Z n-za-mN-ZA-M' -alias xlock='ssh-add -D && xlock -mode blank' -alias 64216="base64-decode | perl -e 'undef \$/; \$a=<>; print unpack(\"H\*\", \$a),\"\n\";'" +#alias xlock='ssh-add -D && xlock -mode blank' +#alias 64216="base64-decode | perl -e 'undef \$/; \$a=<>; print unpack(\"H\*\", \$a),\"\n\";'" +alias 64216='perl -MMIME::Base64 -e "print unpack(\"H*\", decode_base64(<>)),\"\n\""' +alias base64-encode='perl -MMIME::Base64 -e "print encode_base64(<>)"' +alias base64-decode='perl -MMIME::Base64 -e "print decode_base64(<>)"' alias vnc='xtightvncviewer -encodings "tight copyrect" -compresslevel 9 -quality 4' alias rdesktop-w='rdesktop -x l -g 1280x1024 -a 16 172.22.118.112' @@ -326,8 +329,7 @@ md() { sd() { fp=$( wget -q -O - http://tor.noreply.org:80/tor/status/authority | \ awk '$1 == "r" && $2 == "'$1'" {printf "%s===", $3}' | \ - base64-decode | \ - perl -e 'undef $/; $a=<>; print unpack("H*", $a),"\n";' ) + perl -MMIME::Base64 -e "print unpack(\"H*\", decode_base64(<>)),\"\n\"" ) echo wget -q -O - http://tor.noreply.org:80/tor/server/fp/$fp } @@ -370,6 +372,7 @@ compdef _ssh sshc=ssh compdef _ssh cssh=ssh #alias scp="scp -S $HOME/bin/ssh" +alias hs-mplayer='mplayer -ao alsa:device=hw=1' [ -e $HOME/.zshrc-local ] && . $HOME/.zshrc-local [ -e $HOME/.pal ] && [ -e /usr/bin/pal ] && pal -r 5-10 |