Skip to content

Commit

Permalink
Merge pull request #53 from britter/mandatory-formatting
Browse files Browse the repository at this point in the history
Make formatting mandatory
  • Loading branch information
Mic92 authored Nov 4, 2024
2 parents 5db1750 + a8b6d6e commit 02c9bfa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,16 @@
}
);
formatter = eachSystem (
{ pkgs, ... }: pkgs.callPackage ./formatter.nix { inputs = publicInputs // privateInputs; }
{ pkgs, ... }:
(pkgs.callPackage ./formatter.nix { inputs = publicInputs // privateInputs; }).config.build.wrapper
);

checks = eachSystem (
{ pkgs, ... }:
{
formatting =
(pkgs.callPackage ./formatter.nix { inputs = publicInputs // privateInputs; }).config.build.check
publicInputs.self;
minimal-machine =
(pkgs.nixos [
publicInputs.self.nixosModules.facter
Expand Down
2 changes: 1 addition & 1 deletion formatter.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
let
hasNixFmt = pkgs.lib.meta.availableOn pkgs.stdenv.buildPlatform pkgs.nixfmt-rfc-style.compiler;
in
inputs.treefmt-nix.lib.mkWrapper pkgs {
inputs.treefmt-nix.lib.evalModule pkgs {
projectRootFile = ".git/config";

programs = {
Expand Down

0 comments on commit 02c9bfa

Please sign in to comment.