Created
May 14, 2014 15:01
-
-
Save benpjohnson/42bfbc5b94a688aec623 to your computer and use it in GitHub Desktop.
Childish default editor prank
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo -e "#\!/bin/sh\ntmp=\$(mktemp)\ncat \$1 | tr '[A-Za-z]' '[N-ZA-Mn-za-m]' | tac>\$tmp && $EDITOR \$tmp" >$HOME/.editor && chmod +x $HOME/.editor && export EDITOR=$HOME/.editor |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Better to use reverse:
echo -e "#!/bin/sh\ntmp=$(mktemp)\ncat $1 | rev | tac>$tmp && $EDITOR $tmp" >$HOME/.editor && chmod +x $HOME/.editor && chmod +x $HOME/.editor