Repository navigation
Let a file need several components (installer.shared_files) - #37
Merged
Merged
Conversation
1 task
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.
Closes #36.
What
A new setting,
installer.shared_files, for components whose patterns overlap:"first"(default): unchanged. A file belongs to the first component that matches it."all": a file belongs to every component that matches it and is installed only when all of them are ticked.That gives the layout from the issue: one "Applications" box, one "Tools" box and one box per vendor, instead of vendors × kinds.
The issue suggested
[files] combine = "all". It lives under[installer]instead, because a macOS-only config has no[files]section.How
componentand adds an optionalalso_needslist, left out when empty, so existing configs build the same manifest.Choices::installsrequires every claim. Unpacking, updates, removal of stale files, free-space and size figures, shortcuts and ZIP profiles all go through it.[[run]]steps whose program isn't installed are skipped.bach checkandbach inspectshow every claim.bach build --msirefuses shared files, since an MSI file belongs to one feature.Compatibility
FORMAT_VERSIONstays 1 on purpose. The updater of an installed app reads the new setup file's manifest with its old code, so a new format number would stop existing installs from updating. The one gap: an online installer built by an older Bach ignoresalso_needsand goes by one component per file. The docs say to publish the newly built web installer with the release that first uses"all".Also in here
bach inspect --jsonprintsplatform, whichschema/bach-output.schema.jsondidn't list.json_output_is_one_object_with_stable_fieldsfailed on a checkout with a built runtime because of it. Fixed in its own commit.Checks
cargo test --workspace,cargo clippy --workspace --all-targets -- -D warningsandcargo fmt --checkpass on Windows.a_silent_install_adds_and_removes_shared_files_with_the_boxesincrates/cli/tests/components.rsis#[ignore]like the other install tests:cargo test -p bach-cli --test components -- --ignored.The attachment in the issue was not downloaded or opened; this is based on the issue text.
🤖 Generated with Claude Code