Skip to content

Commit 03b124c

Browse files
committed
cmd/git(fix[init]): Don't pass --shared when shared=False
why: Both shared=True and shared=False were passing --shared flag. Per git-init docs, --shared without value defaults to group permissions. shared=False should mean "no --shared flag", not default group sharing. what: - Only append --shared when shared is explicitly True - shared=False now behaves like shared=None (no flag)
1 parent a6245ae commit 03b124c

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/libvcs/cmd/git.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1256,7 +1256,9 @@ def init(
12561256
"everybody",
12571257
}
12581258
if isinstance(shared, bool):
1259-
local_flags.append("--shared")
1259+
if shared:
1260+
local_flags.append("--shared")
1261+
# shared=False means no --shared flag (same as None)
12601262
else:
12611263
shared_str = str(shared).lower()
12621264
# Check if it's a valid string value or an octal number

0 commit comments

Comments
 (0)