Last active
December 30, 2015 08:59
-
-
Save missinglink/7806099 to your computer and use it in GitHub Desktop.
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
#!/bin/bash | |
echo '--- 1 ---' | |
ls -1 | cowsay | |
function pause { | |
read -p "$*" | |
} | |
function multi { | |
while read -r; do | |
for i in ${@:1}; do | |
$i $REPLY; | |
done | |
done | |
} | |
pause 'Press [Enter] key to continue...' | |
echo '--- 2 ---' | |
ls -1 | multi cowsay |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment