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

etc/packager: checksum does not seem right #1440

Open
affeldt-aist opened this issue Dec 19, 2024 · 3 comments
Open

etc/packager: checksum does not seem right #1440

affeldt-aist opened this issue Dec 19, 2024 · 3 comments
Labels
packaging/releasing Issue/PR about packaging or realising.
Milestone

Comments

@affeldt-aist
Copy link
Member

That's the second time that I use etc/packager and this is a great help. Thank you @proux01 .
However, it does not seem to generate the right checksum for me
(twice I had to fix it by hand to release the opam packages).

First, I thought that I was a victim of macOS sed.
Maybe adding a SED=sed variable to packager could mitigate the issue with macOS (so that it is easier to set it to gsed--GNU sed).

However, this did not fix my problem.
Second, I thought that it was due to the URL of the archive.
As explained in the HOWTORELEASE https://github.com/math-comp/analysis/wiki/HOWTORELEASE
we need to download the archive once and put it back so that we do not rely on the URL.
As a consequence, what used to be
https://github.com/math-comp/analysis/archive/refs/tags/1.8.0.tar.gz
is now
https://github.com/math-comp/analysis/releases/download/1.8.0/analysis-1.8.0.tar.gz
I adjusted packager by changing the variable ARCHIVEURL to
ARCHIVEURL="https://github.com/math-comp/analysis/releases/download/$TAG/analysis-$TAG.tar.gz"
but for some reason I haven't figured out, the wrong checksum is still computed.

Which leads me to the conclusion that my shell skills are too limited. Do you have a clue of what I did wrong? @proux01

@affeldt-aist affeldt-aist added this to the 1.9.0 milestone Dec 19, 2024
@proux01
Copy link
Collaborator

proux01 commented Dec 19, 2024

No idea, what I usually do to get the hash is something like curl -sL <url> | sha512sum

@affeldt-aist affeldt-aist modified the milestones: 1.9.0, 1.10.0 Feb 19, 2025
@affeldt-aist
Copy link
Member Author

observed when releasing version 1.9.0:
etc/packager is downloading
https://github.com/math-comp/analysis/archive/1.9.0.tar.gz
while it should be
https://github.com/math-comp/analysis/archive/analysis-1.9.0.tar.gz

@affeldt-aist
Copy link
Member Author

Another problem is more BSD/MacOS specific: the four occurrences of sed in the script need to be replaced by gsed (I couldn't figure how to globally replace sed (not sure it is a good idea also) and an alias in the shell is not enough apparently).

@affeldt-aist affeldt-aist added the packaging/releasing Issue/PR about packaging or realising. label Feb 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
packaging/releasing Issue/PR about packaging or realising.
Projects
None yet
Development

No branches or pull requests

2 participants