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

Version 0.1.2 #1

Closed
wants to merge 90 commits into from
Closed

Version 0.1.2 #1

wants to merge 90 commits into from

Conversation

infinixbot
Copy link
Owner

Version 0.1.2

infinisil and others added 30 commits March 21, 2024 01:41
At least the output from `npins update nixpkgs`
This script fuly automates releases. In a future commit this will be run by CI

I ran the script once to generate the initial version 0.1.0: https://github.com/NixOS/nixpkgs-check-by-name/releases/tag/0.1.0
This calls the release script whenever a commit is pushed to the main branch, such that merging a PR
that increases the version number immediately causes a new release

This also turns off the other CI for pushes to the main branch, doesn't seem necessary
Improves upon the automated update PRs introduced in NixOS#12 to resolve issues brought up in the first automated PR NixOS#14.

* Give more information about the updates, not much, but at least the output of npins update
* Update all npins sources, not just Nixpkgs.
* Run `cargo update`
* Make it trigger CI by using an unprivileged separate machine account (welcome, @infinixbot!)
* Set committer and author of the commits to the machine account
This sets up automated releases, mainly so that we can distribute a pre-built version of the tool, allowing Nixpkgs' CI to fetch it without building.
Set `GH_TOKEN` to fix automated releases
Don't commit PR body for automated updates
Fix automated updates (another try)
And make it also build the autoPrUpdate derivation
See NixOS#20 (comment)

We fix this by telling the update scripts explicitly which files they should update and passing that
information in from CI
Need to set the correct path to create the PR from..
It can be derived from the package_name
to avoid confusing it with a valid package_name where relative_package_dir could
be derived.
infinisil and others added 28 commits April 8, 2024 23:12
The command isn't very reproducible anyways, since it depends on certain files existing.
Printing a reproducible command is up to callers like Nixpkgs:
https://github.com/NixOS/nixpkgs/blob/4cba8b53da471aea2ab2b0c1f30a81e7c451f4b6/.github/workflows/check-by-name.yml#L115
By turning Nix eval errors into a NixpkgsProblem.

With the convention of NixpkgsProblem representing problems caused by Nixpkgs, and
I/O-Result errors caused by bugs in the program, it should've really been of the first variant all
along.

Some workarounds are required to make the testing of this feasible
Second release out of this repository. I'm excited!
Now using `nix-build -A <tab>` is much smaller
Makes the diff smaller for a future non-trivial update script
Using the dependabot CLI
Many different script updates along the way as well.
lazyDerivation limits which attributes are exposed, and version is not currently one of them,
so we need to explicitly expose it.

This fixes this CD failure:

https://github.com/NixOS/nixpkgs-check-by-name/actions/runs/8637321506/job/23679230914
Previously the closing </details> tag was not printed if there was nothing to update, which leads to
wrong nesting
Fix output markdown of update-github-actions
Automated release
@infinixbot infinixbot closed this Apr 18, 2024
@infinixbot infinixbot deleted the release branch April 18, 2024 21:42
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.

4 participants