Conversation
39e4fce to
32ee3ca
Compare
bbc09b4 to
d963946
Compare
7dfd3b7 to
46545b6
Compare
43d6048 to
1e961e0
Compare
dad4550 to
f653545
Compare
094a030 to
a66f899
Compare
2a01847 to
5be31fd
Compare
277318e to
b8a682b
Compare
Closed
4311a19 to
ace4f84
Compare
This was referenced Dec 24, 2022
Merged
Closed
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
@latestversion in all tools installed from GH releasesCloses #1
Closes #5
Closes #25
TODO:
should we use sha256 or sha512/256 instead of sha512 to reduce the size of the manifest files?UPD: Changed to use sha256 as it seems to reduce the overall size of the manifest by almost half.UPDATE: manifest size issue is currently tracked by #36.
Details
This switches package info management from code in shellscript to JSON manifest. The following is an example of the manifest:
install-action/manifests/mdbook.json
Lines 2 to 20 in f30d182
These manifests are generated by a manifest generator written in Rust. The generator uses base package info like the following, fetches Release info from GitHub API, finds releases that include specified assets, downloads assets, gets SHA256 checksums, and dumps these info as manifests.
install-action/tools/codegen/base/mdbook.json
Lines 1 to 14 in f30d182
Multiple asset name patterns can be specified, and if no assets match the first pattern, check the second pattern. So it works well even if the asset name changes in a new release (just insert the new asset name to the front of the asset name list). The following is the case of cross, which changed asset names in 0.2.2.
install-action/tools/codegen/base/cross.json
Lines 4 to 7 in f30d182
install-action/manifests/cross.json
Lines 62 to 91 in f30d182
The generator is run regularly in CI, and a PR is created if there is a release that does not yet exist in the manifest.