Radish alpha
r
rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5
Radicle web interface
Radicle
Git
Add update script for heartwood version and flake
Archived did:key:z6Mkgfwr...BYQp opened 2 years ago

Use this script to update tests/support/heartwood-version and keep the flake in sync with it.

Alternatively, run the script as

scripts/update-flake $(cat tests/support/heartwood-version)

to bring the flake back into sync.

This also updates the flake.lock and the updates the state of the npm dependencies when run from a nix-enabled system.

did:key:z6Mkgfwr...BYQp opened with revision 0779d6c6 on base fca515ab +68 -19 2 years ago

Use this script to update tests/support/heartwood-version and keep the flake in sync with it.

Alternatively, run the script as

scripts/update-flake $(cat tests/support/heartwood-version)

to bring the flake back into sync.

This also updates the flake.lock and the updates the state of the npm dependencies when run from a nix-enabled system.

did:key:z6Mkgfwr...BYQp commented on revision 1 2 years ago

Note: I also inverted the nixpkgs dependency. This means, radicle-interface uses the exact build (including the rust toolchain etc.) from the referenced heartwood revision by follow-ing nixpkgs from there. This should ensure bug compatibility.

did:key:z6MkkfM3...sVz5 reviewed 2 years ago

Nice patch spacefrogg!

I would prefer if the script didn’t edit the heartwood-version file and only reads it, to obtain the data for editing the nix related files like nix.flake. Also we should try to match the command help, please look into the other scripts for it.

did:key:z6Mkgfwr...BYQp commented on revision 1 2 years ago

This started off, because rudolfs mentioned he wouldn’t want to have to perform two steps to update the heartwood version. As mentioned in the patch description, you can nullify the effect of editing heartwood-version by reading the hash from it. I could make this the default, if the script is called without arguments. It would satisfy both requirements.

did:key:z6Mkgfwr...BYQp pushed revision 2 056772e7 on base fca515ab +92 -19 2 years ago
did:key:z6MkkfM3...sVz5 reviewed 2 years ago

Thanks spacefrogg for addressing my feedback!

I have a nit related to MacOS, for some reason MacOS uses a different flavour of sed than linux distros like nix, arch, etc.

More details here on the differences between gnu-sed and “normal” sed

I’m not sure if we can workaround it, else I would at least tell people on MacOS to get gnu-sed aka gsed so they don’t get regex issues like I did as following:

sed: 1: "/url.*git\+https.*z3gqc ...": \1 not defined in the RE
did:key:z6Mkgfwr...BYQp pushed revision 3 4c39ee25 on base fca515ab +92 -19 2 years ago
did:key:z6Mkgfwr...BYQp commented on revision 3 2 years ago

I changed the order of the arguments. Please try again!

did:key:z6MkkfM3...sVz5 reviewed 2 years ago

Hmm this seems to work, but instead of overwriting the git url in flake.nix with the correct revision I get a new file named flake.nix-e..

did:key:z6Mkgfwr...BYQp pushed revision 4 2c118daf on base fca515ab +94 -19 2 years ago
did:key:z6MkkfM3...sVz5 accepted 2 years ago

Nice!

That works as intended, good job!

rudolfs pushed revision 5 009131f2 on base 76ed6399 +0 -0 2 years ago

Rebase.