4. Integrated Development
Environment
The primary rationale for using an IDE
is that it gathers all your tools in the
same place, and you can use them in
concert with roughly the same user
interface paradigm, and without
having to exert too much effort to make
separate applications cooperate.
5. Using UNIX as IDE
● Shell tips
● ZSH
● Moving around
● Terminal multiplexor
● Composing commands
● Customizing applications
7. #1 I need to run a long
command I ran previously
Wrong:
● lookup the parameters and type it all again
● <up> <up> <up> ....
● grep .bash_history
Good:
● <c-r>, start typing, <c-r> to scroll results
8. #2 Oops, I made a typo
Wrong
● <left> <left> <backspace> <backspace> ....
Good
● <c-u> - deletes from cursor to the beginning
● <c-k> - deletes from cursor to the end
● <c-w> - deletes word before cursor
● <c-a> - move to the beginning
● <c-e> - move to the end
Better
● use vi-mode
9. #3 I need to switch to a
different application
e.g., I am in vim and want to try something in
irb
Wrong:
● open new terminal window
Good
● <c-z> to suspend
● fg to resume
10. #4 I need to disconnect
from remote machine
Wrong
● Ok, I'll wait
Good
● <c-z> to suspend
● bg to run in background
● disown to ignore SIGHUP
11. #5 I forgot sudo
Wrong
● <up> <c-a> sudo <cr>
Good
● sudo !!
● !! is alias for last command
Better
● Custom keybinding that inserts sudo
12. #6 I want to change this
file's extension
Wrong
● cp /opt/nginx/conf/nginx.conf
/opt/nginx/conf/nginx.conf.bak
Good
● cp /opt/nginx/conf/nginx.conf{,.bak}
13. #7 I want to exit the shell
Wrong
● type 'exit'
● click close button
Good
● <c-d>