Skip to content

Do not remove folder if clone crashes - #15

Merged
hellska merged 3 commits into
mainfrom
do-not-remove-folder-if-clone-crashes
Jul 29, 2026
Merged

Do not remove folder if clone crashes#15
hellska merged 3 commits into
mainfrom
do-not-remove-folder-if-clone-crashes

Conversation

@francesconazzaro

@francesconazzaro francesconazzaro commented Jul 28, 2026

Copy link
Copy Markdown
Member

Previously, git_clone_repo deleted the existing target folder up front, then cloned directly into it — so a failed clone (bad ref, auth error, network issue) left the folder gone with nothing to replace it.

This clones into a temporary directory first and only swaps it into the target path once the clone succeeds, so a failed clone now leaves the previous checkout untouched. git_clone_repos also catches clone/filesystem errors per-repo and logs them instead of aborting the whole run, so one bad repo (e.g. <org>/* glob with many repos) doesn't stop the rest from being cloned.

Also includes minor repo hygiene: a .gitignore and a default VS Code Python interpreter setting.

@malmans2 malmans2 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the .vscode folder intended, or do you need to add it to .gitignore?

@hellska
hellska merged commit 2da1a7d into main Jul 29, 2026
2 checks passed
@hellska
hellska deleted the do-not-remove-folder-if-clone-crashes branch July 29, 2026 14:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants