Skip to content

Instantly share code, notes, and snippets.

@skoch
Created May 16, 2014 16:42
Show Gist options
  • Save skoch/b23d687b04661fcea534 to your computer and use it in GitHub Desktop.
Save skoch/b23d687b04661fcea534 to your computer and use it in GitHub Desktop.
Toggle Hidden Files
try
set state to do shell script "defaults read com.apple.finder AppleShowAllFiles" as string
if state is "NO" then
do shell script "defaults write com.apple.finder AppleShowAllFiles YES && killall Finder"
else
do shell script "defaults write com.apple.finder AppleShowAllFiles NO && killall Finder"
end if
end try
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment