Created
October 12, 2012 15:45
-
-
Save mattintosh4/3879875 to your computer and use it in GitHub Desktop.
シェルスクリプトサンプル
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
for f in "$@" | |
do | |
ln -s "${f}" "${f}.link" | |
done |
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
case "$(defaults read com.apple.finder CreateDesktop)" in | |
0) defaults write com.apple.finder CreateDesktop -bool YES;; | |
1) defaults write com.apple.finder CreateDesktop -bool NO;; | |
esac | |
killall Finder |
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
case "$(defaults read com.apple.finder AppleShowAllFiles)" in | |
0) defaults write com.apple.finder AppleShowAllFiles -bool YES;; | |
1) defaults write com.apple.finder AppleShowAllFiles -bool NO;; | |
esac | |
killall Finder |
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
. "${HOME}"/.bashrc | |
for f in "$@" | |
do | |
wine "$f" & | |
done |
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
for f in "$@" | |
do | |
/opt/X11/bin/xterm -e bash -c ". ${HOME}/.bashrc; wine \"$f\"" & | |
done |
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
/opt/local/bin/7z a -mx=0 "$1.zip" "$@" -xr\!.DS_Store |
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
cat |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment