Repository navigation
update-vlang-graph: delete the linker's manifest sidecars after a build - #143
Merged
Merged
Conversation
The Windows linker writes a `<exe>.manifest` beside each exe it builds. build_one renames the build into place and never removed the sidecar, so every build left `graphify.exe.new.exe.manifest` and similar files in bin/, untracked. The manifest is already embedded in the exe, which runs without the sidecar (checked with a hello-world build), so build_one now removes the sidecars after the swap. Removal is best-effort, as the other cleanup in build_one is, so a failure leaves litter but doesn't fail the build. Co-Authored-By: WOZCODE <contact@withwoz.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The Windows linker writes a
<exe>.manifestbeside each exe it builds.build_onerenames the build into place and never removed that sidecar, so every build left files such asbin/graphify.exe.new.exe.manifestbehind, untracked (bin/*.newin.gitignoredoesn't match them).build_onenow deletes the sidecars after a successful swap:tmp + '.manifest'(the sidecar of the.new.exeit just built), andout + '.manifest'(any older sidecar of the final name).Checks
hello.new.exe.manifest, and the exe still ran (printedhi, exit 0).or {}), like the other cleanup inbuild_one. A failure leaves litter but cannot fail a build.<name>.new.exe.manifestbehind. The next successful build of the same binary uses the same temporary name, so it removes it then.bin/update-vlang-graph.vshcompiles withv build.Review:
/vreview, standard mode, full-file read of the script; the swallowed-write detector reports no findings.🧙 Built with WOZCODE