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.
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.
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.
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.
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.
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
I changed the order of the arguments. Please try again!
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..
Nice!
That works as intended, good job!
Rebase.