treewide: format all files (#57)
Run `nix fmt` at the root of the repository to format all files. I've done this on my fork and this will help me merge your changes later without having to deal with un-formatted files.
This commit is contained in:
parent
70f8b2360f
commit
0f42b0eebb
21 changed files with 369 additions and 164 deletions
90
flake.nix
90
flake.nix
|
|
@ -12,51 +12,59 @@
|
|||
};
|
||||
};
|
||||
|
||||
outputs = {
|
||||
nixpkgs,
|
||||
nixvim,
|
||||
flake-parts,
|
||||
pre-commit-hooks,
|
||||
...
|
||||
} @ inputs:
|
||||
flake-parts.lib.mkFlake {inherit inputs;} {
|
||||
systems = ["aarch64-linux" "x86_64-linux" "aarch64-darwin" "x86_64-darwin"];
|
||||
outputs =
|
||||
{
|
||||
nixpkgs,
|
||||
nixvim,
|
||||
flake-parts,
|
||||
pre-commit-hooks,
|
||||
...
|
||||
}@inputs:
|
||||
flake-parts.lib.mkFlake { inherit inputs; } {
|
||||
systems = [
|
||||
"aarch64-linux"
|
||||
"x86_64-linux"
|
||||
"aarch64-darwin"
|
||||
"x86_64-darwin"
|
||||
];
|
||||
|
||||
perSystem = {
|
||||
system,
|
||||
pkgs,
|
||||
self',
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
nixvim' = nixvim.legacyPackages.${system};
|
||||
nvim = nixvim'.makeNixvimWithModule {
|
||||
inherit pkgs;
|
||||
module = ./config;
|
||||
};
|
||||
in {
|
||||
checks = {
|
||||
default = pkgs.nixvimLib.check.mkTestDerivationFromNvim {
|
||||
inherit nvim;
|
||||
name = "A nixvim configuration";
|
||||
perSystem =
|
||||
{
|
||||
system,
|
||||
pkgs,
|
||||
self',
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
nixvim' = nixvim.legacyPackages.${system};
|
||||
nvim = nixvim'.makeNixvimWithModule {
|
||||
inherit pkgs;
|
||||
module = ./config;
|
||||
};
|
||||
pre-commit-check = pre-commit-hooks.lib.${system}.run {
|
||||
src = ./.;
|
||||
hooks = {
|
||||
statix.enable = true;
|
||||
nixfmt-rfc-style.enable = true;
|
||||
in
|
||||
{
|
||||
checks = {
|
||||
default = pkgs.nixvimLib.check.mkTestDerivationFromNvim {
|
||||
inherit nvim;
|
||||
name = "A nixvim configuration";
|
||||
};
|
||||
pre-commit-check = pre-commit-hooks.lib.${system}.run {
|
||||
src = ./.;
|
||||
hooks = {
|
||||
statix.enable = true;
|
||||
nixfmt-rfc-style.enable = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
formatter = pkgs.nixfmt-rfc-style;
|
||||
|
||||
packages.default = nvim;
|
||||
|
||||
devShells = {
|
||||
default = with pkgs; mkShell { inherit (self'.checks.pre-commit-check) shellHook; };
|
||||
};
|
||||
};
|
||||
|
||||
formatter = pkgs.nixfmt-rfc-style;
|
||||
|
||||
packages.default = nvim;
|
||||
|
||||
devShells = {
|
||||
default = with pkgs;
|
||||
mkShell {inherit (self'.checks.pre-commit-check) shellHook;};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue