Describe the bug
A clear and concise description of what the bug is:
- Cloned a repo in
--bare and added main branch as git worktree add
- Hoped the default configuration would work
- Getting
Failed to get closest revision in that exists in remote 'origin' error
To Reproduce
- Provide a minimal lua configuration that reproduces the bug:
...just the default config with no changes to mappings, callbacks or anything else is fine.
- Describe the steps to reproduce the behavior:
- Do
git clone --bare https://github.com/ruifm/gitlinker.nvim && cd gitlinker.nvim.git && git worktree add main
- Change to
main and open a file there, e.g. README.md
- press
<leader>gy (default mapping). The error Failed to get closest revision in that exists in remote 'origin' should appear.
Expected behavior
Open README.md for main branch of 'ruifm/gitlinker.nvim' on GitHub.
System (please complete the following information):
- OS: macos
- git version 2.37.1 (Apple Git-137.1)
- Neovim:
NVIM v0.8.3
Build type: Release
LuaJIT 2.1.0-beta3
Compiled by brew@Ventura-arm64.local
Features: +acl +iconv +tui
See ":help feature-compile"
system vimrc file: "$VIM/sysinit.vim"
fall-back for $VIM: "/opt/homebrew/Cellar/neovim/0.8.3/share/nvim"
Run :checkhealth for more info
Describe the bug
A clear and concise description of what the bug is:
--bareand addedmainbranch asgit worktree addFailed to get closest revision in that exists in remote 'origin'errorTo Reproduce
...just the default config with no changes to mappings, callbacks or anything else is fine.
git clone --bare https://github.com/ruifm/gitlinker.nvim && cd gitlinker.nvim.git && git worktree add mainmainand open a file there, e.g.README.md<leader>gy(default mapping). The errorFailed to get closest revision in that exists in remote 'origin'should appear.Expected behavior
Open
README.mdformainbranch of 'ruifm/gitlinker.nvim' on GitHub.System (please complete the following information):