cli/pkg/cmd/repo/setdefault
Mislav Marohnić 8df1e9946f
repo set-default: support bare git repos
The command was using this to check for git repo context:

    git rev-parse --is-inside-work-tree

With this change, this is used instead:

    git rev-parse --git-dir

The latter approach works in the context of a bare git repository, which does not have a worktree.
2023-01-18 20:45:12 +01:00
..
setdefault.go repo set-default: support bare git repos 2023-01-18 20:45:12 +01:00
setdefault_test.go repo set-default: support bare git repos 2023-01-18 20:45:12 +01:00