Skip to content

[24.11] workflows/{editorconfig,keep-sorted}: drop and move to treefmt#405811

Merged
wolfgangwalther merged 2 commits into
NixOS:release-24.11from
wolfgangwalther:ci-backport-treefmt-editorconfig
May 10, 2025
Merged

[24.11] workflows/{editorconfig,keep-sorted}: drop and move to treefmt#405811
wolfgangwalther merged 2 commits into
NixOS:release-24.11from
wolfgangwalther:ci-backport-treefmt-editorconfig

Conversation

@wolfgangwalther
Copy link
Copy Markdown
Contributor

Backport of #405684.

Had a conflict in the OWNERS file, otherwise applied cleanly.

Things done


Add a 👍 reaction to pull requests you find important.

We already have treefmt running for nixfmt, so it's easy to just add
another formatter to it. This gives a much better UX, because all
formatting errors are reported through the same channel.

It also saves us one CI job, which takes most of the time to just set up
the machine, clone the repo and download Nix - while doing a minimum of
actual work.

Total execution time for treefmt is ~10% slower:
- 38s only nixfmt
- 43s nixfmt + editorconfig-checker

(cherry picked from commit ba4fe10)
Same reasoning as the commit before, but keep-sorted has even less
overhead than editorconfig-checker. Benchmark has it at 1 second per
run.

(cherry picked from commit 1cb7a38)
@github-actions github-actions Bot added 6.topic: continuous integration Affects continuous integration (CI) in Nixpkgs, including Ofborg and GitHub Actions 4.workflow: backport This targets a stable branch 6.topic: policy discussion Discuss policies to work in and around Nixpkgs labels May 10, 2025
@github-actions github-actions Bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. labels May 10, 2025
@wolfgangwalther wolfgangwalther merged commit 82d7645 into NixOS:release-24.11 May 10, 2025
23 of 27 checks passed
@wolfgangwalther wolfgangwalther deleted the ci-backport-treefmt-editorconfig branch May 10, 2025 07:37
@winterqt
Copy link
Copy Markdown
Member

winterqt commented May 14, 2025

Pretty sure this broke formatting CI on 24.11, see all of the red in https://github.com/NixOS/nixpkgs/pulls?q=is%3Apr+base%3Arelease-24.11.

@wolfgangwalther
Copy link
Copy Markdown
Contributor Author

I think it was #406681, but yes. Some files on release-24.11 are still not valid for editorconfig, apparently. I have it on my list to fix for today, but still busy with other stuff. Feel free to fix the offending files :)

@Mic92
Copy link
Copy Markdown
Member

Mic92 commented May 14, 2025

#407058

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4.workflow: backport This targets a stable branch 6.topic: continuous integration Affects continuous integration (CI) in Nixpkgs, including Ofborg and GitHub Actions 6.topic: policy discussion Discuss policies to work in and around Nixpkgs 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants