diff --git a/cmd/git-sync/main.go b/cmd/git-sync/main.go index 01ce454..60550ed 100644 --- a/cmd/git-sync/main.go +++ b/cmd/git-sync/main.go @@ -1285,6 +1285,10 @@ func setupDefaultGitConfigs(ctx context.Context) error { // How to manage credentials (for those modes that need it). key: "credential.helper", val: "cache --timeout 3600", + }, { + // Our working root is safe (avoid a "dubious ownership" error). + key: "safe.directory", + val: "*", }} for _, kv := range configs { if _, err := cmdRunner.Run(ctx, "", nil, *flGitCmd, "config", "--global", kv.key, kv.val); err != nil {