diff --git a/lib/git-subrepo b/lib/git-subrepo index cfeeae92..2117ec45 100755 --- a/lib/git-subrepo +++ b/lib/git-subrepo @@ -1231,7 +1231,7 @@ command-setup() { local _worktree _worktree=$( git worktree list | - grep "\[subrepo/$subdir\]" | + grep "\[subrepo/$subref\]" | cut -d ' ' -f1 ) || true if [[ $command =~ ^(commit)$ && -z $_worktree ]]; then