Skip to content

.github/workflows/check-commits.yml: check for the existence of fixup…#167312

Closed
Artturin wants to merge 2 commits intoNixOS:masterfrom
Artturin:checkfixupcommits
Closed

.github/workflows/check-commits.yml: check for the existence of fixup…#167312
Artturin wants to merge 2 commits intoNixOS:masterfrom
Artturin:checkfixupcommits

Conversation

@Artturin
Copy link
Member

@Artturin Artturin commented Apr 5, 2022

… commits

oftentimes people forget to either fixup the fixup! commits or forget to
squash merge

this should prevent that from happening

Description of changes
Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 22.05 Release Notes (or backporting 21.11 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

… commits

oftentimes people forget to either fixup the fixup! commits or forget to
squash merge

this should prevent that from happening
@Artturin Artturin requested review from a team, Mic92 and zowoq as code owners April 5, 2022 09:07
@github-actions github-actions bot added the 6.topic: policy discussion Discuss policies to work in and around Nixpkgs label Apr 5, 2022
@zowoq
Copy link
Contributor

zowoq commented Apr 5, 2022

Does this really happen that often that we need an action? Can you show some data from the git history?

@Artturin Artturin force-pushed the checkfixupcommits branch from 58c8fc9 to 3e75ae8 Compare April 5, 2022 09:20
@zowoq
Copy link
Contributor

zowoq commented Apr 5, 2022

People probably won't like getting a ❌ on PRs that could be squashed.

@Artturin
Copy link
Member Author

Artturin commented Apr 5, 2022

theres notice, warning, and error messages
https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#setting-a-notice-message

i don't know if warnings show up as a red X
if they do then it could be a notice

@zowoq
Copy link
Contributor

zowoq commented Apr 5, 2022

theres notice, warning, and error messages

That is for the message, I'm talking about the check status. AFAIK is has to be either green or red.

@ofborg ofborg 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 Apr 5, 2022
@zowoq
Copy link
Contributor

zowoq commented Apr 5, 2022

Looks like you're trying to test this here, it won't actually work unless it is on master. As it doesn't need any of the nixpkgs code I'd suggest creating a personal repo to test it in, that is what I usually do.

@zowoq
Copy link
Contributor

zowoq commented Apr 5, 2022

There are other actions and apps on the marketplace that we could for this (and other commit lint/style checks) which may be better than writing and needing to maintain our own.

Adding it to ofborg (which does support neutral check status) might be a better option as well.

@Artturin Artturin marked this pull request as draft April 9, 2022 13:07
@Artturin Artturin closed this Apr 24, 2022
@Artturin Artturin deleted the checkfixupcommits branch April 24, 2022 00:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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.

2 participants