0%

TMUX and VIM in ubuntu

Learning to use a new language is not easy. Learning to use all the shortcut keys of TMUX and VI also takes time.

Today, I want to record what I had learnt about TMUX and Vi.

While, I should divided this post into two posts, but TMUX only takes a little ink, so I just put it here.

TMUX is a tool to help you divide your screen of your terminals into several screens. Whenever you want to use hotkeys, you have to press Ctrl + B first, then you can press the hot key. You can change the pre hot key, but I just leave it unchanged. The most used keys are the following:
REMEMBER to press Ctrl+B first!!
% #divide screen left and right
“ #divede screen up and down
Ctrl + Down #make the down screen smaller
exit #cancel present screen
n #new dash window

That is it.

Then let me record the tips of VI. Well it is much complex than the former. Generally, it has three mode, i mode(insert and edit), v mode(copy and paste), and : mode(file operation). Ok let me write down the most used keys:
Ctrl +: #this will let you enter the file operation mode
i #this will let you enter the edit mode, Press Esc to enter : mode
v #this will let you enter copy and paste mode, Press Esc to enter : mode

When you press ‘v’ in the : mode, you can press Arrow Button to select the text you want to copy or delete, and then press:
y #copy
d #delete
p #paste
Ctrl+: #show clipped board
:%s/ski/sky/g #replace ski with sky in all place

How to save file
:w filename
:w! filename
:wq #quit and save
:q! #quit not save

How to open file
:open filename
:open ~/luke/code/try.py

How to search in a file
:/ pattern
:? pattern
n:search next
N:search previous

How to cancel and redo
:u for cancel
Ctrl + R:redo

How to paste from system clipboard
shift+insert
+p

Isn’t easy. But it takes time to get used to them and operate unconsioucely.

I also want to keep down some hot keys of Ubuntu, let me google first. Ok here are they:
Ctrl + Alt + L lock the desktop
Win applications desktop
Ctrl + Alt + Left shift to left desktop
Alt + Tab shitt applications
Alt + F4 shut down present application
Ctrl+Win+Up Maxilize present window
Ctrl+Win+Down Minilize presnet window
Ctrl+Alt+T Open terminal
$ command1 && command2 # execute command1 first and succeed then execute command2
Ctrl+Shift+Arrow Shift Workplace
Ctrl+Shift+Alt+Arrow move present window to Workplace

Want to know more, click here
Now almost done, and wait to be expanded.

感谢您的鼓励和打赏!