Skip to content

Commit

Permalink
treefmt: disable yamlfmt newline trimming
Browse files Browse the repository at this point in the history
Signed-off-by: Paul Meyer <[email protected]>
  • Loading branch information
katexochen committed Jul 4, 2024
1 parent ec93820 commit 0536a3d
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion treefmt.nix
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
shellcheck.enable = true;
shfmt.enable = true;
statix.enable = true;
yamlfmt.enable = true;
# keep-sorted end
};
settings.formatter = {
Expand Down Expand Up @@ -49,5 +48,14 @@
"LICENSE"
];
};
# TODO(katexochen): move back to programs after
# https://github.com/numtide/treefmt-nix/pull/193 is merged.
yamlfmt = {
command = "${lib.getExe pkgs.yamlfmt}";
options = [
"-formatter=retain_line_breaks_single=true"
];
includes = [ "*.yaml" "*.yml" ];
};
};
}

0 comments on commit 0536a3d

Please sign in to comment.