Created
November 23, 2010 15:40
-
-
Save itayd/711952 to your computer and use it in GitHub Desktop.
flips second and rest of arguments for a command
This file contains hidden or 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/sh | |
first=$1 | |
second=$2 | |
shift 2 | |
after=$* | |
exec $first $after $second |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
example:
flip.sh scp [email protected]:
/ blaexecutes
scp bla [email protected]:/