Few tips for mac
- 2min
-
Add script here :
/usr/local/bin
-
Screenshot system :
defaults write com.apple.screencapture name “Anything you like”; killall SystemUIServer
-
Size of dock icons :
defaults write com.apple.dock largesize -int 512; killall Dock
-
Hidden files shown :
defaults write com.apple.finder AppleShowAllFiles TRUE; killall Finder
-
Zip a file with a password:
zip -e [archive] [file]
-
Zip a folder:
zip -r [archive] [folder]
-
Zip a folder with a password:
zip -re [archive] [folder]
-
Delete every file starting with ._ :
dot_clean -m .
-
Alternative:
-
How To Block Websites on Your Mac Using Terminal:
- Edit
/etc/hosts
- Add 127.0.0.1 https://www.google.com/ (exemple)
- Execute this to update:
sudo dscacheutil -flushcache
- Edit
-
Clean DNS Cache:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
orsudo dscacheutil -flushcache
-
Path for user’s dictionaries :
~/Library/Dictionaries