By default, macOS shows accent options (é,è,ê) when holding keys - great for typing. But it’s problematic in apps like VSCode and Cursor where you may have enabled Vim bindings. Then you want key repeat, like holding ‘j’ to move down in Vim.
Here’s how to enable key repeat instead:
VSCode:
defaults write com.microsoft.VSCode ApplePressAndHoldEnabled -bool false
Cursor:
defaults write com.todesktop.230313mzl4w4u92 ApplePressAndHoldEnabled -bool false
To revert back to accent menu:
defaults write com.microsoft.VSCode ApplePressAndHoldEnabled -bool true
defaults write com.todesktop.230313mzl4w4u92 ApplePressAndHoldEnabled -bool true
Remember to restart the app after applying.
Note: Cursor’s unusual bundle ID is permanent due to app release constraints (source). You can identify bundle id’s yourself by running osascript -e 'id of app "Cursor"'
Originally posted on twitter.
Yesterday I messed up 🤦♂️ I accidentally deleted my shell config file.
It was a brain fart. I wanted to open the file with vim. Instead I typed rm.
rm ~/.zshrc
It happened in the office. I felt so stupid. My colleagues made a fun of me. But they also showed me a cool tool to avoid making this mistake again.
So here's how to protect yourself against accidentally deleting config files:
Originally posted on twitter.
Does anyone else use the imgcat library to show matplotlib plots directly in iTerm?
Image credits: Nicolas P. Rougier's Scientific Visualization book
Yes, plotting in Jupyter is nicer...but I think it's pretty neat that this is possible. And sometimes it's quicker too 😁
Originally posted on twitter.
What's the first thing you do when you get a new mac? 🧑💻
For me it's setup the hyper key.
It removes your caps lock functionality and gives you something much much better:
1️⃣ an escape key that's comfy for your pinky
2️⃣ a hyper key that's never occupied by other shortcuts
No other app uses these shortcuts:
⬆️ shift
^ control
⌥ option
⌘ command
+...another letter
So if you get the hyper key you get a comfortable shortcut combination that's never blocked!
And that's important, when you want to have some shortcuts available everywhere.
Keep reading for examples: