Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix main.sh: bail on semver operators #26

Merged
merged 3 commits into from
Oct 3, 2022

Conversation

NobodyXu
Copy link
Collaborator

@NobodyXu NobodyXu commented Oct 3, 2022

Signed-off-by: Jiahao XU Jiahao_XU@outlook.com

@NobodyXu NobodyXu force-pushed the fix-cargo-binstall branch 4 times, most recently from c4086c8 to 522ca21 Compare October 3, 2022 10:50
Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
Copy link
Owner

@taiki-e taiki-e left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

main.sh Outdated Show resolved Hide resolved
Co-authored-by: Taiki Endo <te316e89@gmail.com>
main.sh Outdated Show resolved Hide resolved
Co-authored-by: Taiki Endo <te316e89@gmail.com>
@taiki-e
Copy link
Owner

taiki-e commented Oct 3, 2022

It's getting so complicated so quickly...

Well, we can also reduce complexity by accepting some odd versions like 0 or 0.0. (I'm fine with either.)

if [[ ! "${version}" =~ ^[0-9]+(\.[0-9]+(\.[0-9]+)?)?(-[0-9A-Za-z\.-]+)?(\+[0-9A-Za-z\.-]+)?$|^latest$ ]]; then

Maybe we should rewrite in python?

I'm not very familiar with python, so there is no possibility to do that in this repository.


Btw, as for reducing the complexity of install-action, improving maintainability, and support for #1, #5, #25, etc., I'm thinking of managing the package information as json or another and fetching the latest version's package information in CI to automatically update (like my other repos I mentioned in #5 (comment)).

@NobodyXu NobodyXu requested a review from taiki-e October 3, 2022 11:59
@NobodyXu
Copy link
Collaborator Author

NobodyXu commented Oct 3, 2022

Well, we can also reduce complexity by accepting some odd versions like 0 or 0.0. (I'm fine with either.)

I'm fine with this PR.

I'm thinking of managing the package information as json or another and fetching the latest version's package information in CI to automatically update (like my other repos I mentioned in #5 (comment)).

That will definitely makes updating a lot easier.

Copy link
Owner

@taiki-e taiki-e left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again!

@taiki-e taiki-e merged commit 9f3710a into taiki-e:main Oct 3, 2022
@NobodyXu NobodyXu deleted the fix-cargo-binstall branch October 3, 2022 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants