I Love Shortcuts!
Every time I learn a new shortcut, I get a little giddy. I don’t quite know why I’m so excited about them, but I am. Some (or all) of these I’m sure you already know, but I thought I’d post some of the recent shortcuts (and other helpful tips) I’ve learned recently.
General Keyboard Shortcuts (for mac)
- command + shift + [left or right arrow] (highlights from the cursor to the end (or beginning, depending on which arrow) of the row)
- command + ~ (switches between windows within the same application)
A note one that last one: I have used command + tab forever to switch between applications, but was always frustrated that I could not go between windows of the same application (chrome, for example). And now I can! Woo Hoo!
Ruby tips (works in Ruby Mine and Sublime Text. untested elsewhere)
- highlight some text, and press ‘ or ” and it will wrap the highlighted text in quotes. (if you already have a string, but want to change from single to double quotes, or vice versa, highlight the string, quotes included, and press ‘ or ” and it will replace the single(double) quotes with double(single) quotes) Awesome!
Command Line Shortcuts
- when changing directories (cd), start typing the directory, and press tab to autofill the matching directory
- cd .. (goes up one directory)
- touch file_name (this will create a file in the current directory. It can be any file type. examples below: