Skip to content

Instantly share code, notes, and snippets.

@tjluoma
Created February 2, 2015 14:05
Show Gist options
  • Select an option

  • Save tjluoma/3102ba11b8647fb6f555 to your computer and use it in GitHub Desktop.

Select an option

Save tjluoma/3102ba11b8647fb6f555 to your computer and use it in GitHub Desktop.
Be sure to change /Users/luomat/ to whatever your $HOME directory is. AppleScript from http://apple.stackexchange.com/a/71755/9226
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>sync.com.tjluoma.cleandesktop</string>
<key>ProgramArguments</key>
<array>
<string>/usr/bin/osascript</string>
<string>-e</string>
<string>tell application "Finder" to clean up window of desktop by name</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>WatchPaths</key>
<array>
<string>/Users/luomat/Desktop</string>
</array>
</dict>
</plist>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment