neovim-gtk
neovim-gtk copied to clipboard
Can't open paths containing '.git' from commandline
Describe the bug
I installed the neovim-gtk-git
package from the AUR.
When I try to open a file in the .git
folder from the commandline, neovim-gtk
opens just a new unnamed file.
Steps to reproduce the bug Go to any Git repository and run
$ nvim-gtk .git/config
Alternatively, you could create any folder named .git
$ mkdir .git
$ touch .git/foo
$ echo bar >> .git/foo
When I open this file with nvim .git/foo
I can see the line "bar", nvim-gtk .git/foo
opens an empty file in the directory containing the .git
folder.
Other files in hidden folders work as expected, e.g.
$ mkdir .bar
$ touch .bar/foo
$ echo baz >> .bar/foo
Both nvim
and nvim-gtk
show the correct file.
Technical information:
- OS: Archlinux
- Neovim version: 0.3.1
- Neovim-Gtk build version:
828a78b68f15aed381d846cb70ff05b127b6d86e
$ nvim --version
NVIM v0.3.1
Build type: Release
LuaJIT 2.0.5
Compilation: /usr/bin/cc -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector-strong -fno-plt -Wconversion -O2 -DNDEBUG -DMIN_LOG_LEVEL=3 -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wimplicit-fallthrough -Wvla -fstack-protector-strong -fdiagnostics-color=auto -Wno-array-bounds -DINCLUDE_GENERATED_DECLARATIONS -D_GNU_SOURCE -DNVIM_MSGPACK_HAS_FLOAT32 -DNVIM_UNIBI_HAS_VAR_FROM -I/build/neovim/src/build/config -I/build/neovim/src/neovim-0.3.1/src -I/usr/include -I/build/neovim/src/build/src/nvim/auto -I/build/neovim/src/build/include
Compiled by builduser
Features: +acl +iconv +jemalloc +tui
See ":help feature-compile"
system vimrc file: "$VIM/sysinit.vim"
fall-back for $VIM: "/usr/share/nvim"
Try it and for me it works. Also neovim 0.2.0 is to old, there was some issues on it, currently minimum supported version is 0.2.2, I use 0.3.1
Sorry, I gave you the nvim-gtk version. My neovim version is 0.3.1 (I edited it in the first comment).
The issue also seems only to occur with folders named exactly .git
.
It works for me too:
nvim --version
NVIM v0.3.2-896-ge53ae88e7
# I have neovim-gtk up to HEAD
nvim-gtk --version
NeovimGtk 0.2.0
I have vim-dirvish installed $ nvim-gtk .git
opens a dirvish buffer with the contents of the .git folder.