···11+22+11.08.2021
33+44+# learning VIM
55+66+77+88+commands I learned and useful
99+1010+1111+zz -> centers your cursor to the middle
1212+; -> if you search something with f or t, it will search for the next one
1313+gg -> start and G -> end
1414+w -> goes one word and W goes further, same for back with b and B
1515+b -> goes one word back
1616+e -> move to the end of your word
1717+% -> toggles between parentese forth and back if your inside one
1818+\* -> toggles through all your variable or word on in your text
1919+o -> will insert a new line and put you into insert mode directly. O will due it above
2020+C -> puts you into insert and replace until end of line
2121+a -> Insert text after the cursor
2222+A -> will put you into i mode and jump to end of line
2323+I -> Insert mode at the beginning of the line
2424+i -> go into insert mode before the cursor
2525+x -> will delete one character where your cursor is
2626+~ -> will toggle the case
2727+ZZ : closes file same as :wq except it will not write anything to disk if nothing has changed. :x does the same
2828+2929+f -> find a character, with ; next. with F you find backward
3030+t -> find to a character. with ; next. With T you find backward
3131+3232+## More Navigation
3333+^U: move up half a screen
3434+^D: move down half a screen
3535+L: puts cursor into lowest part of your code
3636+M: puts cursor in the middle part of your code
3737+H: puts cursort to the top (high?) part of your code
3838+Ctrl-i: jump to your previous navigation location
3939+ctrl-r : replace
4040+Ctrl-o: jump back to where you were
4141+J: join the current line with the next one (delete what's between)
4242+4343+## visual mode
4444+v -> visual mode (characters)
4545+V -> line mode
4646+ctrl + v -> column mode!
4747+ctrl+v and any command after hit ESC -> will do it on all selected lines of columns
4848+4949+## recording macros
5050+q -> record macros! after you need to say where to save. e.g. safe on a character. you can applay it with @ and that character. hit q to stop/save the recording.
5151+5252+5353+. -> redo any cmd you did before !!
5454+5555+## text-objects or nouns
5656+p -> change paragraph
5757+w -> word
5858+s -> sentense
5959+6060+[ ( { < -> A [], (), or {} block
6161+t -> tag
6262+b -> block B-> block in
6363+R -> Insert mode -> replaces existing text
6464+r -> replace one character
6565+6666+# Learnings
6767+Ctrl+r" - Insert the contents of the " register, aka the last yank/delete. e.g. if you want to replace single quotes with double: ciw'Ctrl+r"'