From eec48ff71881d8757b79dcd95aac9dac4d71bf72 Mon Sep 17 00:00:00 2001 From: Max Christian Pohle Date: Sun, 12 May 2024 21:01:00 +0200 Subject: tidied this repo up and uploaded my new nvim from scratch config --- doc/coderonline-vim.png | Bin 91868 -> 0 bytes doc/git | 2 - doc/git.txt | 3 - doc/gtk.css | 7 -- doc/list-of-filetypes.txt | 175 --------------------------------------- doc/readme.md | 15 ---- doc/screen.txt | 9 -- doc/shortcuts.txt | 206 ---------------------------------------------- 8 files changed, 417 deletions(-) delete mode 100644 doc/coderonline-vim.png delete mode 100644 doc/git delete mode 100644 doc/git.txt delete mode 100644 doc/gtk.css delete mode 100644 doc/list-of-filetypes.txt delete mode 100644 doc/readme.md delete mode 100644 doc/screen.txt delete mode 100644 doc/shortcuts.txt (limited to 'doc') diff --git a/doc/coderonline-vim.png b/doc/coderonline-vim.png deleted file mode 100644 index 156ff3a..0000000 Binary files a/doc/coderonline-vim.png and /dev/null differ diff --git a/doc/git b/doc/git deleted file mode 100644 index 1205d00..0000000 --- a/doc/git +++ /dev/null @@ -1,2 +0,0 @@ -undo last commit: git reset HEAD~ -diff two branches: git diff branch1 branch2 path/to/file diff --git a/doc/git.txt b/doc/git.txt deleted file mode 100644 index 517f998..0000000 --- a/doc/git.txt +++ /dev/null @@ -1,3 +0,0 @@ -GIT_PAGER=less git config --list | awk 'match($0, "submodule.(.*).url=(.*)",q){ system("echo git submodule add " q[2] " " q[1]) }' - -branchvv = for-each-ref --sort='committerdate:raw' --format='%(HEAD)%(if)%(HEAD)%(then)%(color:bold green)%(end) %(align:width=24)%(refname:short)%(end) %(objectname:short) %(color:bold blue)%(committerdate:iso)%(color:reset) %(if)%(upstream)%(then)[%(color:blue)%(upstream:short)%(color:reset)] %(end)%(subject)' refs/heads diff --git a/doc/gtk.css b/doc/gtk.css deleted file mode 100644 index 5f15661..0000000 --- a/doc/gtk.css +++ /dev/null @@ -1,7 +0,0 @@ -/* to be saved as ~/.config/gtk-3.0/gtk.css - * thanks to http://stackoverflow.com/users/6899000/proprefenetre */ -@define-color YOUR_BACKGROUND_COLOR #rrggbb; - -window#vim-main-window { - background-color: @YOUR_BACKGROUND_COLOR; -} diff --git a/doc/list-of-filetypes.txt b/doc/list-of-filetypes.txt deleted file mode 100644 index 9752c6a..0000000 --- a/doc/list-of-filetypes.txt +++ /dev/null @@ -1,175 +0,0 @@ -# this list can be generated with ':setfiletype '. I have copied it to -# make it searchable. - -2html erlang master sinda -HGAnnotate eruby matlab sindacmp -PKGBUILD esmtprc maxima sindaout -a2ps esqlc mel sisu -a65 esterel messages skill -aap eterm mf sl -abap euphoria3 mgl slang -abaqus euphoria4 mgp slice -abc eviews mib slim -abel exim mix slpconf -acedb expect mma slpreg -ada exports mmix slpspi -aflex falcon mmp slrnrc -ahdl fan modconf slrnsc -alsaconf fasm model sm -amiga fdcc modsim3 smarty -aml fetchmail modula2 smcl -ampl fgl modula3 smil -ansible fish monk smith -ansible_hosts flexwiki moo sml -ansible_template focexec mp snnsnet -ant form mplayerconf snnspat -antlr forth mrxvtrc snnsres -apache fortran msidl snobol4 -apachestyle foxpro msmessages solidity -aptconf framescript msql spec -arch freebasic mupad specman -arduino fstab mush spice -art fvwm mustache splint -asciidoc fvwm2m4 muttrc spup -asm gdb mysql spyce -asm68k gdmo named sql -asmh8300 gedcom nanorc sqlanywhere -asn git nasm sqlforms -aspperl gitcommit nastran sqlhana -aspvbs gitconfig natural sqlinformix -asterisk gitolite ncf sqlj -asteriskvm gitrebase netrc sqloracle -atlas gitsendemail netrw sqr -augeas gkrellmrc nginx squid -autohotkey glsl nim srec -autoit gnash ninja sshconfig -automake gnomecat nix sshdconfig -ave gnuplot nosyntax st -avra go nqc stata -awk godefstack nroff stp -ayacc godoc nsis strace -b gohtmltmpl obj stylus -baan gotexttmpl objc sudoers -basic gp objcpp svg -bc gpg ocaml svn -bdf gprof occam swift -bib grads octave syncolor -bib_latexSuite gretl omnimark synload -bindzone groff opencl syntax -blade groovy openroad sysctl -blank group opl systemd -bst grub ora systemverilog -btm gsp pamconf tads -bzl gtkrc papp tags -bzr haml pascal tak -c hamster passwd takcmp -cabal handlebars pcap takout -calendar haskell pccts tap -catalog haste pdf tar -cdl hastepreproc perl taskdata -cdrdaoconf haxe perl6 taskedit -cdrtoc haxe_extended pf tasm -cf hb pfmain tcl -cfg help pgsql tcsh -ch hercules php teraterm -chaiscript hex phtml terminfo -change hgcommit pic tex -changelog hitest pike tex_LatexBox -chaskell hog pilrc tex_latexSuite -cheetah hostconf pine texinfo -chill hostsaccess pinfo texmf -chordpro hss plaintex text -cl html plantuml textile -clean html5 pli tf -clipper htmlcheetah plm thrift -clojure htmldjango plp tidy -cmake htmlm4 plsql tilde -cmake-indent htmlos po tli -cmake-syntax hxml pod tmux -cmusrc ia64 postscr tomdoc -cobol ibasic pov toml -coco icemenu povini tpp -coffee icon ppd trasys -color_coded idl ppwiz treetop -colortest idlang prescribe trustees -conaryrecipe indent privoxy tsalt -conf inform procmail tsscl -config initex progress tssgm -context initng prolog tssop -cpp inittab promela tt2 -cql ipfilter proto tt2html -crm ishd protocols tt2js -crontab iss ps1 twig -cryptol ist ps1xml typescript -crystal j psf uc -cs jal ptcap udevconf -csc jam pug udevperm -cscope_plus jargon puppet udevrules -csdl jasmine purescript uil -csh java purifylog updatedb -csp javacc pyrex upstart -css javascript python upstreamdat -cterm jess qf upstreaminstalllog -ctrlh jgraph qml upstreamlog -cucumber jinja2 quake upstreamrpt -cuda jovial r usserverlog -cupl jproperties racc usw2kagtlog -cuplsim json radiance vala -cuda jovial r usserverlog -cupl jproperties racc usw2kagtlog -cuplsim json radiance vala -cvs jsp ragel valgrind -cvsrc jst ratpoison vb -cweb jsx rc vbnet -cynlib julia rcs vcl -cynpp kconfig rcslog velocity -d kivy readline vera -dart kix rebol verilog -datascript kotlin redif verilogams -dcd kscript registry vgrindefs -dcl kwt remind vhdl -debchangelog lace resolv vim -debcontrol latextoc reva vimgo -debsources latte rexx viminfo -def ld rhelp virata -denyhosts ldapconf rib vmasm -desc ldif rmd voscm -desktop less rnc vrml -dictconf lex rng vroom -dictdconf lftp rnoweb vsejcl -diff lhaskell robots vundlelog -dircolors libao rpcgen wdiff -dirpager lifelines rpl web -diva lilo rrst webmacro -django limits rspec wget -dns liquid rst whitespace -dnsmasq lisp rtf winbatch -docbk lite ruby wml -docbksgml litestep rust wsh -docbkxml logcheck samba wsml -dockerfile loginaccess sas wvdial -dosbatch logindefs sass xbl -dosini logtalk sather xdefaults -dot lotos sbt xf86conf -doxygen lout scala xhtml -dracula lpc scala.xpt xinetd -dsl lprolog scheme xkb -dtd lscript scilab xmath -dtml lsl screen xml -dtrace lss scss xmodmap -dts lua sd xpm -dylan lynx sdc xpm2 -dylanintr m4 sdl xquery -dylanlid mail sed xs -ecd mailaliases sendpr xsd -edif mailcap sensors xsl -eelixir make services xslt -eiffel mallard setserial xxd -elf man sgml yacc -elinks manconf sgmldecl yaml -elixir manual sgmllnx z8a -elm maple sh zimbu -elmfilt markdown sicad zsh -ember-script masm sieve -emblem mason simula - diff --git a/doc/readme.md b/doc/readme.md deleted file mode 100644 index 5ea6da4..0000000 --- a/doc/readme.md +++ /dev/null @@ -1,15 +0,0 @@ -vim configuration -================= - -This is the configuration I am using. - - -Screenshot ----------- - - - screenshot of vim - - - - diff --git a/doc/screen.txt b/doc/screen.txt deleted file mode 100644 index 5c375d2..0000000 --- a/doc/screen.txt +++ /dev/null @@ -1,9 +0,0 @@ -To run vim inside a screen session: - -TERM=vte-256color screen vim - -works very well. But if you are using another terminal you may be interested in -other possibilities, like this: - -find /usr/share/terminfo/ | grep screen | grep 256 - diff --git a/doc/shortcuts.txt b/doc/shortcuts.txt deleted file mode 100644 index 5e911ea..0000000 --- a/doc/shortcuts.txt +++ /dev/null @@ -1,206 +0,0 @@ -:viusage = summary of all keyboard shortcuts -:options = shows currently :set options (with descriptions) -leader key = usually set to backslash expects a quick command - - -[normal mode] -f{char} = move cursor to the character {char} -gf = open file under cursor -gf = open file under cursor in a tab -] = jump to the tag under the cursor in a new window - = jump back from where that ^ brought you -K = keyword lookup for the word under the cursor (see :help kp) -w = next word -e = end of word (=inner word) - - -@see: :h text-objects -ci' = change between single quote -ci" = change between double quote -ci( = change between brace -cit = change XML Tag -ciw = select inner word -caw = select 'a word' -" where c can be replaced by v for visual mode - -:%s/foo/bar/g = replace all foo with bar -:g/foo/s/bar//g = on lines with foo replace bar with nothing -:g!/foo/s/bar//g = on lines not containing foo replace bar with nothing -:g!/^foo/execute("normal dd") delete lines starting with foo - -flags, end: after the last / -g = replace globally (all occurances on the current line) -c = confirm each replace, also allows to switch to g (use the flag to see the help message) -e = places the cursor in the end of the selection - -flags, within the search string: -\v = use very magic search (more like perl) -\V = use no very magic, more like searching verbatim -\zs .. \ze = mark begin and end of a sub pattern (like perl lookaround assertions) - - - -[visual mode] # with selected lines -gq = formats text so that it fits in whatever :set textwidth was set -iB = select block between curly braces (:help object-select) - - -[commands] -command line mode begins with : and has its own key mappings starting with c like in cnormap - -:spell [word] = adds a word to the current dictionary (no mistake any more) -:set list = display non printable characters -:retab = replaces tabs with spaces -:set expandtab = in insert mode: replace tab with spaces -:Explore = cli version open file dialog (file explorer) -:Lex = use netrw as project drawer (stays open in its own window) -:only = 'maximize' current buffer - - = auto completion with the word under the cursor (interesting with incsearch) - = expand pattern from command line (e.g. *.txt) - - -[navigation] - = look up the tag under the cursor (help links as well) - = return back from tag under the cursor -gd = jump to the declaration of the variable under the cursor - - -[macros] # record and play back a series of vim commands -qa = start (q) macro recording in register a (can be anything) -q = stop macro recording -@a = replay macro a -:'<,'>normal @a = apply a to every line in the current selection -:reg = lists all registers (including those with macros in them) - -[registers] -notice, that registers get used for both: macro recordings and copying text - -:reg = shows contents of all registers -"0p = pasts from register 0, which is the same as "", but not overwritten by dd -"ap = same for register a -"0yy = yanks to register 0 (same as y by itself) -"ay = yanks current selection to register a (in visual mode) - - -[marker] -ma = set marker a-z (a in this case) -mA = create a session persistent file marker which can be used to reopen a file (not bound to the buffer) -`a = go to marker a (line & column) -'a = go to marker a (line, first non blank), same as `a^ - - - -[hotkeys] -, = increment, decrement number under the cursor - - -[windows] -v = splits buffer vertically (screen uses |) -s = splits buffer horizontally (same as screen) -w = moves the cursor to the next window and back -[dir] = moves the cursor in that direction (use hjkl or arrow keys) -[HK] = make a vertical split horizontal and vice versa -o = only: close all other windows -c = close: current window in which the cursor sits - - -[vimdiff] -do = get changes from other window into the current -dp = put changes from current window into the other -]c = jump to the next change -[c = jump to the prevous change - -[folds] -za = toggle a fold -zM = close all folds -zR = opens all folds (unfold all) -zE = eliminates all folds - - -[buffers] -:bn = buffer next -:bp = buffer previous -:bd = buffer dispatch (close) -:b = switch buffer by name (use and ) -:set nobuflisted = hide buffer in buffer list (great for neovim's terminal) - -[args] -:n **/*.c = opens all files with that name or type in buffers and also fills the argument list - - -[special] -g CTRL-g = display file properties including word and char count -q: = show command history and use it like a normal buffer -z= = show spellcheck suggestions - - -[completions] -CTRL-O = display completions: omnicomplete (context dependant completions) - -CTRL-X CTRL-F = display completions: file name (using vim-internals omnicomplete) -CTRL-N CTRL-P = display completions: file keywords -CTRL-K = display completions: dictionary -CTRL-T = display completions: thesaurus -CTRL-I = display completions: include files -CTRL-] = display completions: tags -CTRL-D = display completions: (marcro-) definitions -CTRL-V = display completions: vim command line -CTRL-U = display completions: user-defined - - -[annoyances] -gv = visual mode: reselect last selection -CTRL-o = lets the caret jump back to the previous location -CTRL-L = redraws the complete screen -CTRL-R = in insert mode and command line: paste contents of (e.g. : for last command, * for clipboard) -CTRL-R = in normal mode: redoes what has been undone with u -"p = in normal mode: paste paste contents of - -[registers] -"/ = last search expression -": = last command entered -"= = expression register (to do calculations or call vim functions) - - - -[netrw] -:Lex = open the netrw-view as project drawer -gn = makes the directory under the cursor the root directory -a = toggles display of hidden files - -[filetype:css] -viB:sort = sort inner block by name - -[vim commands] -:for i in range(1,12) | put ='2016-'.i | endfor - -[fancy utf-8 symbols] -௵ - -[debugging] -:profile! start /tmp/profile.log -:profile func * -:profile file * -" At this point do slow actions -:profdel * -:e /tmp/profile.log -" add a break point to a vim script (like vimrc) to invoke the internal debugger -:breakadd here - -:finish = from within a viml-script: stop sourcing it - -[substitutions] -delete all comments: %s/\/\*\*< [^(\*\/)]*\*\///g -remove empty lines: global/^$/d -remove non-empty lines: v/^$/d - -[programs] -gpm - cut and paste helper for the linux console (to get text from CTRL-ALT-F2 to CTRL-ALT-F3) - - -[vim modeline] -filetype can have multiple values, like python.django -The last line can be a mode line, which holds settings like tab width: - -# vim: noai:ts=2:sw=2 filetype=dosini.text -- cgit v1.2.3