Skip to content

Instantly share code, notes, and snippets.

@jaskfla
Last active April 15, 2024 02:34
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jaskfla/f086f495745ee54912de09ac9895e4b8 to your computer and use it in GitHub Desktop.
Save jaskfla/f086f495745ee54912de09ac9895e4b8 to your computer and use it in GitHub Desktop.
macOS Tidbits

Clarus the dogcow macOS Tidbits

Some neat conveniences for macOS users (or just the macOS-curious).


When ⌘↹-ing between apps, you can mouse over over an app and release ⌘ to switch to that app without having to spam ↹ or ⇧↹.

⌥⌘-click an app in the Dock to switch to that app and hide all other apps at the same time. This is great when screen sharing.

Hold ⌘ to interact with background windows without bringing them into focus.


When using the mouse to select text, double-click to select a words. Triple-click to select a paragraph.

Relatedly, double-click and drag to select word-by-word. Triple-click and drag to select paragraph-by-paragraph.


When taking screenshots, hold ⌃ to copy the image instead saving it to your desktop.

Relatedly, you can make screenshots save somewhere else.

When using ⇧⌘4 to take screenshots, press Space to take screenshots of windows. In this mode, you can also:

  • hold ⌥ to take the window screenshot sans-shadow; and/or
  • hold ⌘ to capture child views within a window—such as open/save dialogues, alert windows, et al.

Relatedly, you can make shadowless default for window screenshots. Hold ⌥ to add the shadow.


⌘-drag to reorder icons in the Menu Bar.

Click and hold the Spotlight button in the Menu Bar to reset its location on screen.


Hold ⇧⌥ to adjust brightness or volume in quarter-increments. This is useful when the lowest click is still too bright or loud.

A quick way to access your Displays settings is to hold ⌥, and press either Brightness Up or Brightness Down. Same goes for Sound settings (⌥Volume Up, ⌥Volume Down, ⌥Mute) and Keyboard settings (⌥Keyboard Brightness Up, ⌥Keyboard Brightness Down). This still works if you have a Touch Bar: hold ⌥ and tap the corresponding button in the Control Strip.


When using drag & drop to copy/move a file, you can hold ⌘ to force Finder to move the file, or hold ⌥ to force Finder to copy the file. (Yes, you can ⌥-drag to duplicate a file within a single folder.)1

In Finder, hold ⌥ to Get Info on all selected items in one Info window, rather than in a barrage of individual windows. This also works with the keyboard shortcut, ⌥⌘I instead of ⌘I.

In any Save sheet, drag and drop a folder onto the sheet to navigate there in the Save sheet. Drag and drop a file to navigate there and prepopulate the “Save As” field with its filename.


You can change the icon of any Finder item: Copy any image or .icns file2, Get Info on any item in Finder, click to select the icon in the top left, and paste! Or simply drag & drop and image or .icns onto the icon.

Relatedly, you can even copy the icon from one file’s Info panel to paste into another.

Also relatedly, a bunch of the system icons live in /System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/.


⌘-click items in the Dock to reveal them in Finder.

Don’t want to accidentally add/remove apps from your Dock? Lock its contents by running:

defaults write com.apple.dock contents-immutable -bool true && killall Dock

Set it back to normal with:

defaults write com.apple.dock contents-immutable -bool false && killall Dock

When macOS says you’ve spelled something wrong, and you right click then choose Learn Spelling, it just adds the word to the ~/Library/Spelling/LocalDictionary file. If you’ve added a word to your dictionary that you no longer want, just open up the file and delete the word.

Relatedly, ⇧⌘G in any Finder window to paste to go straight to the right folder.


Drag and drop a folder onto the Terminal icon to open a terminal directly to that directory.3

Relatedly, ⌘-drag a folder onto a Terminal window to cd there without typing anything.4

Test your network capacity without any third party things (like speedtest.net or fast.com) by running networkQuality from the command line. For example:

> networkQuality
==== SUMMARY ====
Uplink capacity: 19.275 Mbps
Downlink capacity: 429.436 Mbps
Responsiveness: Medium (181.818 milliseconds | 330 RPM)
Idle Latency: 26.312 milliseconds | 2307 RPM

Footnotes

  1. By default, macOS will move the file if you’re dragging within the same drive. If you drag to a Finder location that’s on a different drive, Finder will copy by default. This is when these modifiers come in handy.

  2. .icns is the Apple Icon Image format, which is used for icons macOS-wide. It’s basically just a container of an icon at different sizes. Why not just scale one image? Designers can use optical sizing to optimise the “same” icon for display at different sizes.

  3. This is just a special case of dragging and dropping a file (or folder) onto any app icon to open it in that app.

  4. This also works in iTerm. Though Terminal is a perfectly adequte terminal emulator, if you'd like a few more bells and whistles, iTerm is worth looking at. As is Warp, but as of February 2024, Warp doesn’t support this ⌘-drag shortcut. Criminal.

@JamesNZL
Copy link

😍

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