-
-
Notifications
You must be signed in to change notification settings - Fork 236
Description
Description
In the context of configuration files version control, I have a bare git repository at the root of my filesystem, e.g. at /.mysystemrepo
.
I have some files which are helpers for the usage of the repository and are not needed by the system to work, but I still want them checked out in my repository. So for to understand the purpose, they can only be placed within the git repository itself in a folder named meta
, i.e. in /.mysystemrepo/meta
.
Now, GitSigns never print any signs on such files, it seems to not consider them as valid trackable files.
However this is perfectly possible with git itself and other cli tools like tig
as long as we provide them with the correct GIT_WORKTREE
and GIT_DIR
.
I have tried all methods I could find:
require('gitsigns').setup {
worktrees = {
{
toplevel = '/',
gitdir = '/.mysystemrepo'
},
}
vim.env.GIT_DIR = "/.mysystemrepo/"
vim.env.GIT_WORK_TREE = "/"
- simply running
GIT_DIR="/.mysystemrepo" GIT_WORK_TREE="/" vim
All three methods make GitSigns work correctly for files everywhere else, but not for any tracked files inside /.mysystemrepo
, when again tig
will correctly show me the diff in its TUI.
Is there somewhere in code where we disable looking at files in the git repository folder ?
Neovim version
0.9.4
Operating system and version
linux rolling
Minimal config
nothing except gitsigns installed and code provided in description