Code Editor-Related Shortcuts
- Ctrl+Shift+Up – copy line under cursor up.
- Ctrl+Shift+Down – copy line under cursor down.
- Alt+Shift+Up – move line under cursor up.
- Alt+Shift+Down – move line under cursor down.
- Alt+Shift+Period – this one is used for selection, every time you press this one the selection widens to capture the next logical syntactic element. For example if you have your cursor over a word, pressing this ones would select the whole word, pressing again would select the whole line. If you’re inside a method definition, pressing it again would select the content of the method (between def ... end), once more would select the whole method. If you continue pressing it, you will eventually select the whole file. Very handy.
- Alt+Shift+Comma – this one is the opposite of the one above, it will narrow the selection every time you press it.