Skip to content

Added, but not committed #14

@nnzv

Description

@nnzv

Reproduce

  1. Open a wiki file
  2. Edit that file
  3. :wq

Expected behavior

Commit the added file on nvim exit.

Neovim Information

% nvim -v
NVIM v0.7.2
Build type: RelWithDebInfo
LuaJIT 2.1.0-beta3
Compilation: /usr/bin/x86_64-pc-linux-gnu-gcc -O2 -pipe -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1 -DNVIM_TS_HAS_SET_MATCH_LIMIT -DNVIM_TS_HAS_SET_ALLOCATOR -Og -g -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wshadow -Wconversion -Wdouble-promotion -Wmissing-noreturn -Wmissing-format-attribute -Wmissing-prototypes -Wimplicit-fallthrough -Wsuggest-attribute=pure -Wsuggest-attribute=const -Wsuggest-attribute=malloc -Wsuggest-attribute=cold -Wvla -fstack-protector-strong -fno-common -fdiagnostics-color=always -DINCLUDE_GENERATED_DECLARATIONS -D_GNU_SOURCE -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -DMIN_LOG_LEVEL=3 -I/var/tmp/portage/app-editors/neovim-0.7.2/work/neovim-0.7.2_build/config -I/var/tmp/portage/app-editors/neovim-0.7.2/work/neovim-0.7.2/src -I/usr/include -I/var/tmp/portage/app-editors/neovim-0.7.2/work/neovim-0.7.2_build/src/nvim/auto -I/var/tmp/portage/app-editors/neovim-0.7.2/work/neovim-0.7.2_build/include
Compiled by portage@localhost

Features: +acl +iconv +tui
See ":help feature-compile"

   system vimrc file: "/etc/vim/sysinit.vim"
  fall-back for $VIM: "/usr/share/nvim"

Run :checkhealth for more info

Additional Information

" ~/.config/nvim/init.vim
set 
  \ nu 
  \ nuw=5
  \ tgc 
  \ et 
  \ ea 
  \ noswf
  \ nohls 
  \ lz
  \ nowb
  \ smc=180
  \ wig=*.o,*.pyc,*pycache*
  \ nosmd
  \ nowrap
  \ vif=NONE
  \ ls=0
  \ nobk 
  \ noru
  \ bg=dark
  \ cb=unnamedplus
  \ ut=1000
  \ so=10
  \ shm=aIF
  \ ts=4
  \ sts=4
  \ sw=4
  \ fcs=eo  \ ut=1000
  \ so=10
  \ shm=aIF
  \ ts=4
  \ sts=4
  \ sw=4
  \ fcs=eob:\ ,


let g:vimwiki_list = [{
	\ 'path': '/home/nzv/.config/nvim/wiki',
	\ 'template_path': '~/.config/nvim/wiki/tpl',
	\ 'template_default': 'default',
	\ 'syntax': 'markdown',
	\ 'ext': '.md',
	\ 'path_html': '~/.cache/vimwiki_html',
	\ 'template_ext': '.tpl'
\}]

au FileType vimwiki 
    \ setl spell wrap nonu ch=2

" Easy buffer navigation
nn <C-J> <C-W><C-J>
nn <C-K> <C-W><C-K>
nn <C-L> <C-W><C-L>
nn <C-H> <C-W><C-H>

" Remove arrow keys in some modes
for key in [
    \  '<Down> <Nop>',
    \  '<Left> <Nop>',
    \ '<Right> <Nop>',
    \    '<Up> <Nop>',
\]
    for mod in ['no', 'no!', 'vn', 'ino', 'cno']
        exe mod key
    endfor
endfor

for p in [
    \ '2html_plugin',
    \ 'getscript',
    \ 'getscriptPlugin',
    \ 'gzip',
    \ 'logipat',
    \ 'matchparen',
    \ 'netrw',
    \ 'netrwFileHandlers',
    \ 'netrwPlugin',
    \ 'netrwSettings',
    \ 'rrhelper',
    \ 'spellfile_plugin',
    \ 'sql_completion',
    \ 'syntax_completion',
    \ 'tar',
    \ 'tarPlugin',
    \ 'vimball',
    \ 'vimballPlugin',
    \ 'zip',
    \ 'zipPlugin',
    \ 'vimsyn_embed',
\]
    exe 'let g:loaded_' . p . '= 1'
endfor

call plug#begin()
    Plug 'hashivim/vim-terraform'
    Plug 'weakish/rcshell.vim'
    Plug 'tpope/vim-commentary'
    Plug 'vimwiki/vimwiki'
    Plug 'tpope/vim-fugitive'
    Plug 'michal-h21/vimwiki-sync'
call plug#end()
syn enable | colo ocean

# cwd: /home/nzv/.config/nvim/wiki
% git remote show origin
* remote origin
  Fetch URL: git@github.com:nnzv/wiki.git
  Push  URL: git@github.com:nnzv/wiki.git
  HEAD branch: main
  Remote branch:
    main tracked
  Local ref configured for 'git push':
    main pushes to main (up to date)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions