chore(nix): add nix hash update automation#217
Merged
oschwartz10612 merged 5 commits intofosrl:mainfrom Dec 23, 2025
Merged
Conversation
4493d85 to
79e312a
Compare
Member
|
LGTM lets see what happens! Thanks Varun |
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.
Community Contribution License Agreement
By creating this pull request, I grant the project maintainers an unlimited,
perpetual license to use, modify, and redistribute these contributions under any terms they
choose, including both the AGPLv3 and the Fossorial Commercial license terms. I
represent that I have the right to grant this license for all contributed content.
Description
This syncs up the latest Nix package, unbreaks the Nix package build, and also attempts to add CI checks/updates for the Nix hash to prevent this from happening in the future.
From now on, whenever a PR is opened, and
go.mod/go.sumare changed, the Nix package is built by CI, and it will fail if the hash is incorrect. Any maintainer can subsequently update the hash themselves, or post the hash in a PR review comment and ask the user to update their PR.Additionally, since Dependabot automates Go package updates, this PR adds an action to run
nix-updatein order to get the new hash, and updates the Dependabot PR with the hash change.Ultimately, the maintainers are still responsible for updating the version number on their own before release. This cannot be automated away, unfortunately.
How to test?
Next time a Dependabot update happens, the Dependabot action should trigger and update the Nix hash.
Additionally, the next time a
go.mod/go.sumchange happens, a successful Nix package build should be a prerequisite for merging.