fix(cli): respect src/bin required-features (fix: #15325) - #15427
Conversation
Package Changes Through a975472There are 2 changes which include tauri-cli with patch, tauri-bundler with patch Planned Package VersionsThe following package releases are the planned based on the context of changes in this pull request.
Add another change file through the GitHub UI by following this link. Read about change files or the docs at github.com/jbolda/covector |
Legend-Master
left a comment
There was a problem hiding this comment.
Thanks!
Also you'll need to sign your commits for me to merge this
https://docs.github.com/en/authentication/managing-commit-signature-verification/signing-commits
|
Just so you know, you'll need to upload your signing public key to GitHub for the commit to be verified |
FabianLars
left a comment
There was a problem hiding this comment.
been using it in the cef branch for a while ✅ 50a6671
|
I'll make an exception and bypass the rules since you did sign the commits, just didn't upload the key yet. Please fix that for future PRs though... |
Summary
Fixes #15325.
get_binariesalready skips Cargo[[bin]]targets when theirrequired-featuresare not enabled. The latersrc/binscan did not know about those skipped manifest targets and added them back by filename.This keeps track of disabled manifest bins and skips matching
src/binentries, while still including them when the feature is enabled.Tests
cargo test --manifest-path crates/tauri-cli/Cargo.toml get_binaries_ignores_src_bin_with_disabled_required_features -- --nocapturecargo test --manifest-path crates/tauri-cli/Cargo.tomlcargo clippy --manifest-path crates/tauri-cli/Cargo.toml --all-targets --all-features -- -D warnings -A clippy::while_let_loopnode .scripts/ci/check-change-tags.js .changes/cli-required-features-src-bin.mdgit diff --checkNote: local Clippy 1.95 reports an existing
while_let_looplint inhelpers/pbxproj.rswithout that targeted allow.