Skip to content

MacOS Section Update#928

Open
YuriySamorodov wants to merge 2 commits intojlevy:masterfrom
YuriySamorodov:master
Open

MacOS Section Update#928
YuriySamorodov wants to merge 2 commits intojlevy:masterfrom
YuriySamorodov:master

Conversation

@YuriySamorodov
Copy link

Adjusted few notes and added the items to MacOS only section:

  • Default Terminal in MacOS is zsh. Although most of the commands listed in this guide will work just fine, please keep in mind some bash scripts may through errors or produce unexpected results.

  • Copy output of any command to a file with pbcopy < file.txt or cat file.txt | pbcopy

  • Paste input from one with pbpaste.

  • Count items in clipboard: pbpaste | wc -l

  • Strip formatting from clipboard: pbpaste | pbcopy.

  • To reveal a folder in Finder, pleae use open -R /path/to/file

  • Show/hide hidden files in Finder: defaults write com.apple.finder AppleShowAllFiles YES && killall Finder.

  • Get detailed hardware info with system_profiler and system_profiler SPHardwareDataType for Mac specs.

  • Check battery status with pmset -g batt and power management settings with pmset -g.

  • View system logs with log show or stream them in real-time with log stream.

  • List all running applications with osascript -e 'tell application "System Events" to get name of every process whose background only is false'.

  • Force quit applications from terminal with killall [AppName] or pkill.

  • Flush DNS cache with sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder.

  • View active network connections with netstat -an or lsof -i.

  • Get current Wi-Fi network with networksetup -getairportnetwork en0.

  • Scan available Wi-Fi networks: /System/Library/PrivateFrameworks/Apple80211.framework/Versions/Current/Resources/airport -s.

Hopefully, these are relevant to this wonderful guide.
There are many more that I would add there, but this requires complete section overhaul. Decided to start with something small first.
If approved will update Russian section as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant