Skip to content

Instantly share code, notes, and snippets.

@mertsalik
Created December 21, 2015 12:07
Show Gist options
  • Save mertsalik/1dce448cb922cecb6f36 to your computer and use it in GitHub Desktop.
Save mertsalik/1dce448cb922cecb6f36 to your computer and use it in GitHub Desktop.
# Adding and removing individual login items from Terminal
# Add an item
osascript -e 'tell application "System Events" to make login item at end with properties {path:"/path/to/itemname", hidden:false}'
# Remove an item
osascript -e 'tell application "System Events" to delete login item "itemname"'
# List all items
osascript -e 'tell application "System Events" to get the name of every login item'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment