This topic will consolidate some useful Mac OSX command line that helps me. If you have something better, please help to share in the comment.

1. Setting the default directory for screenshoot the desktop

Command: defaults write com.apple.screencapture location /Users/kevin/Downloads/

Screenshot command:

  • Full screen: Command + Shift + 3
  • Full screen (caching): Command + Control + Shift + 3
  • Selected screen: Command + Shift + 4
  • Selected screen (caching): Command + Control + Shift + 4

2. Zip or Unzip the folder

Command: zip -r foldername.zip foldername/

Command: unzip filename.zip

Topics #cli #mac osx