summaryrefslogtreecommitdiff
path: root/checks/nixfmt
diff options
context:
space:
mode:
authorseth <[email protected]>2024-06-30 09:40:43 -0400
committerGitHub <[email protected]>2024-06-30 09:40:43 -0400
commit509221abec375464985cb45eaf4636e361c13b41 (patch)
tree412bded195b8b90548725c3150adee5970a87965 /checks/nixfmt
parent842c3f225677aa55e44b94342f19c8f3e6f2be06 (diff)
feat: add nixfmt check (#3)
Diffstat (limited to 'checks/nixfmt')
-rw-r--r--checks/nixfmt/package.nix10
1 files changed, 10 insertions, 0 deletions
diff --git a/checks/nixfmt/package.nix b/checks/nixfmt/package.nix
new file mode 100644
index 0000000..ab4d88c
--- /dev/null
+++ b/checks/nixfmt/package.nix
@@ -0,0 +1,10 @@
+{
+ lib,
+ runCommand,
+ nixfmt-rfc-style,
+ root,
+}:
+runCommand "check-nixfmt" {} ''
+ ${lib.getExe nixfmt-rfc-style} --check ${root}
+ touch $out
+''