vim

NameLast commit messageLast commit date
libadapt man.vim to work on plan94 years ago
protoinitial import5 years ago
testdirinitial import5 years ago
xxdinitial import5 years ago
arabic.cinitial import5 years ago
arabic.hinitial import5 years ago
ascii.hinitial import5 years ago
buffer.cinitial import5 years ago
charset.cinitial import5 years ago
diff.cinitial import5 years ago
digraph.cinitial import5 years ago
edit.cinitial import5 years ago
eval.cadd plan9 to feature list (thanks shurizzle)2 years ago
ex_cmds.cinitial import5 years ago
ex_cmds.hinitial import5 years ago
ex_cmds2.cinitial import5 years ago
ex_docmd.cinitial import5 years ago
ex_eval.cinitial import5 years ago
ex_getln.cinitial import5 years ago
farsi.cinitial import5 years ago
farsi.hinitial import5 years ago
feature.hinitial import5 years ago
fileio.cinitial import5 years ago
fold.cinitial import5 years ago
getchar.cinitial import5 years ago
globals.hinitial import5 years ago
gui.cinitial import5 years ago
gui.hinitial import5 years ago
gui_beval.cinitial import5 years ago
gui_beval.hinitial import5 years ago
hardcopy.cinitial import5 years ago
hashtab.cinitial import5 years ago
keymap.hinitial import5 years ago
macros.hinitial import5 years ago
main.aapinitial import5 years ago
main.cinitial import5 years ago
mark.cinitial import5 years ago
mbyte.cinitial import5 years ago
memfile.cinitial import5 years ago
memline.cinitial import5 years ago
menu.cinitial import5 years ago
message.cinitial import5 years ago
misc1.cinitial import5 years ago
misc2.cfix shell escape for rc (thanks shurizzle)2 years ago
mkfilemkfile: add rule to install runtime files and clean pathdef.c (thanks shurizzle)2 years ago
move.cinitial import5 years ago
mysigninitial import5 years ago
nbdebug.cinitial import5 years ago
nbdebug.hinitial import5 years ago
netbeans.cinitial import5 years ago
normal.cchange keyword behaviour to handle man pages4 years ago
ops.cinitial import5 years ago
option.cinitial import5 years ago
option.hinitial import5 years ago
os_plan9.cfix fd leak (thanks shurizzle)2 years ago
os_plan9.hinitial import5 years ago
pathdef.cinitial import5 years ago
popupmnu.cinitial import5 years ago
proto.hinitial import5 years ago
quickfix.cinitial import5 years ago
README.mdREADME: mention updated version maintained by shurizzle2 years ago
README.txtinitial import5 years ago
regexp.cinitial import5 years ago
regexp.hinitial import5 years ago
screen.cinitial import5 years ago
search.cinitial import5 years ago
spell.cinitial import5 years ago
structs.hinitial import5 years ago
syntax.cinitial import5 years ago
tag.cinitial import5 years ago
term.chandle function keys (F1-F12)4 years ago
term.hinitial import5 years ago
termlib.cinitial import5 years ago
ui.cinitial import5 years ago
undo.cinitial import5 years ago
version.cinitial import5 years ago
version.hinitial import5 years ago
vim.hinitial import5 years ago
vim.pngadd screenshot4 years ago
vim.protoinitial import5 years ago
window.cinitial import5 years ago
README.md

vim

This is a plan9 port of the vim editor. The port was initially done by stefanha (see https://vmsplice.net/9vim.html).

This fork builds on the initial port and brings a couple extra features (plumber, mouse support) but also bug fixes (mainly shell command execution).

NOTE: An updated version is available here: https://git.sr.ht/~shurizzle/9vim/

vim

plan9 integration:

Here are a couple of things I use to help with integration within plan9.
VIM loads its configuration from $home/lib/vimrc.

mk

To make mk output recognized by quickfix, use the following:

set errorformat+=%tarning:\ %f:%l\ %m
set errorformat+=%tarning:\ %f:%l[%.%#]\ %m
set errorformat+=%f:%l\ %m
set errorformat+=%f:%l[%.%#]\ %m
autocmd BufReadPost quickfix nnoremap <buffer> <CR> <CR>

grep

I use g for grepping through code. You can modify the grepprg variable to do this:

set grepprg=g\ $*

man pages

The included man.vim plugin is modified to work on plan9. First you need to load the plugin:

runtime ftplugin/man.vim

You can now look at man pages using

:Man <keyword>

In addition, you can change the keywordprg variable to display man pages when pressing the K key over a keyword:

set keywordprg=:Man

function signatures

I use the following function to display the signature of the function under the cursor:

function! s:Sig()
	echo system("sig ".expand("<cword>"))
endfunction
command! Sig call s:Sig()

git diff

I use the following function to display the result of git/diff in the current directory as a diff file:

function! s:GitDiff()
	32 new
	setlocal buftype=nofile
	:.!git/diff
	setlocal ft=diff
endfunction
command! Gd call s:GitDiff()

Issues

  • Input is borked (nothing beyong ascii, leader key, etc.)
  • Other things I'm sure