flake: use nixfmt-rfc-style
This commit is contained in:
parent
e7b8922920
commit
3307e8259d
13 changed files with 398 additions and 167 deletions
55
flake.nix
55
flake.nix
|
@ -1,34 +1,53 @@
|
|||
{
|
||||
description = "Alqages, packages from alqueva to here.";
|
||||
|
||||
inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; };
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
};
|
||||
|
||||
outputs = inputs@{ self, nixpkgs, }:
|
||||
outputs =
|
||||
inputs@{ self, nixpkgs }:
|
||||
let
|
||||
inherit (nixpkgs) lib;
|
||||
eachSystem = f:
|
||||
nixpkgs.lib.genAttrs [ "x86_64-linux" "aarch64-linux" ] (system:
|
||||
eachSystem =
|
||||
f:
|
||||
nixpkgs.lib.genAttrs [ "x86_64-linux" "aarch64-linux" ] (
|
||||
system:
|
||||
f {
|
||||
inherit system;
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
});
|
||||
in {
|
||||
overlays.default = _: prev:
|
||||
}
|
||||
);
|
||||
in
|
||||
{
|
||||
overlays.default =
|
||||
_: prev:
|
||||
lib.pipe (builtins.readDir ./packages) [
|
||||
(lib.filterAttrs (_: v: v == "directory"))
|
||||
(lib.concatMapAttrs (name: _: {
|
||||
${name} = prev.callPackage ./packages/${name} { inherit inputs; };
|
||||
}))
|
||||
(lib.concatMapAttrs (
|
||||
name: _: {
|
||||
${name} = prev.callPackage ./packages/${name} { inherit inputs; };
|
||||
}
|
||||
))
|
||||
];
|
||||
|
||||
packages = eachSystem ({ pkgs, ... }: self.overlays.default pkgs pkgs);
|
||||
devShells = eachSystem ({ pkgs, ... }: {
|
||||
default = pkgs.mkShell {
|
||||
name = "alqages-dev";
|
||||
packages =
|
||||
builtins.attrValues { inherit (pkgs) nil nixfmt deadnix statix; };
|
||||
};
|
||||
});
|
||||
formatter = eachSystem ({ pkgs, ... }: pkgs.nixfmt);
|
||||
devShells = eachSystem (
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
default = pkgs.mkShell {
|
||||
name = "alqages-dev";
|
||||
packages = builtins.attrValues {
|
||||
inherit (pkgs)
|
||||
nil
|
||||
nixfmt
|
||||
deadnix
|
||||
statix
|
||||
;
|
||||
};
|
||||
};
|
||||
}
|
||||
);
|
||||
formatter = eachSystem ({ pkgs, ... }: pkgs.nixfmt-rfc-style);
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue