Flake environment with pre-commit hook; CI to enforce them. #2

Merged
Niols merged 4 commits from pre-commit-and-ci into main 2024-11-14 17:51:17 +01:00
Owner

This PR introduces a basic flake environment and a basic CI. The flake contains very little; basically only a pre-commit hook for Nix formatting and Nix dead code detection. The CI only enforces those. This is meant as a building stone for other later PRs.

This PR introduces a basic flake environment and a basic CI. The flake contains very little; basically only a pre-commit hook for Nix formatting and Nix dead code detection. The CI only enforces those. This is meant as a building stone for other later PRs.
Niols added 3 commits 2024-11-14 01:30:52 +01:00
Niols added 1 commit 2024-11-14 09:50:22 +01:00
Niols added 1 commit 2024-11-14 09:51:05 +01:00
fricklerhandwerk approved these changes 2024-11-14 10:56:25 +01:00
fricklerhandwerk left a comment
Owner

Works. Shameless plug, because I think pre-commit is quite slow and needlessly complex: I've wrote a very thin Nix layer around setting Git hooks directly, which can be combined with treefmt-nix. Maybe for one day. (My thing still needs options to do more hooks than just pre-commit)

Works. Shameless plug, because I think pre-commit is quite slow and needlessly complex: I've wrote [a very thin Nix layer around setting Git hooks directly](https://github.com/fricklerhandwerk/git-hooks), which can be combined with [treefmt-nix](https://github.com/numtide/treefmt-nix/). Maybe for one day. (My thing still needs options to do more hooks than just pre-commit)
Author
Owner

Ooh, that would be nice, because I agree with the statement that “pre-commit is quite slow and needlessly complex”. I will not merge the PR right away because, somehow, the CI is not triggering, and I don't understand why. It might be just a Forgejo repository configuration issue, because it previously worked in Fediversity/simple-nixos-fediverse#25. I will investigate.

Ooh, that would be nice, because I agree with the statement that “pre-commit is quite slow and needlessly complex”. I will not merge the PR right away because, somehow, the CI is not triggering, and I don't understand why. It might be just a Forgejo repository configuration issue, because it previously worked in https://git.fediversity.eu/Fediversity/simple-nixos-fediverse/pulls/25. I will investigate.
Niols force-pushed pre-commit-and-ci from 0bcaf844a4 to a888540580 2024-11-14 17:50:31 +01:00 Compare
Niols merged commit 7ac8ec85cc into main 2024-11-14 17:51:17 +01:00
Niols deleted branch pre-commit-and-ci 2024-11-14 17:51:19 +01:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Fediversity/Fediversity#2
No description provided.