Clone operations now use a temp directory to completely isolate from any git repository at the process cwd. This fixes the issue where `.git` directory was deleted during `gt rig add` when the town root was initialized with `--git`. The fix applies to all four clone functions: - Clone() - CloneBare() - CloneWithReference() - CloneBareWithReference() Each function now: 1. Creates a temp directory 2. Runs clone inside temp dir with cmd.Dir set 3. Sets GIT_CEILING_DIRECTORIES to prevent parent repo discovery 4. Moves the cloned repo to the final destination
38 KiB
38 KiB