mirror of
https://github.com/runkids/skillshare.git
synced 2026-11-18 18:04:17 +00:00
The legacy target migration wrote to the predictable path config.yaml.tmp next to the validated destination. A cloned project could ship that name as a symlink to a file outside the project, so merely loading the project overwrote the outside file and the rename then replaced the project config with the link. Create the temp file with os.CreateTemp in the destination directory, which never follows an existing name, and remove it if any step fails.