feat: basic flake-parts structure, make-shell, files and readme
This commit is contained in:
parent
6c59366f8f
commit
a19ede01a2
7 changed files with 127 additions and 28 deletions
29
flake.nix
29
flake.nix
|
@ -3,18 +3,23 @@
|
|||
# nixos-unstable provides a binary cache for all packages.
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
# flake-parts lets us define flake modules.
|
||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
flake-parts = {
|
||||
url = "github:hercules-ci/flake-parts";
|
||||
inputs.nixpkgs-lib.follows = "nixpkgs";
|
||||
};
|
||||
# import-tree imports all nix files in a given directory.
|
||||
import-tree.url = "github:vic/import-tree";
|
||||
# files lets us write text files and automatically add checks for them
|
||||
files.url = "github:mightyiam/files";
|
||||
# make-shells.<name> creates devShells and checks
|
||||
make-shell = {
|
||||
url = "github:nicknovitski/make-shell";
|
||||
inputs.flake-compat.follows = "dedupe_flake-compat";
|
||||
};
|
||||
|
||||
# The following are not used but are here for deduplication.
|
||||
dedupe_flake-compat.url = "github:edolstra/flake-compat";
|
||||
};
|
||||
|
||||
outputs =
|
||||
inputs@{ self, ... }:
|
||||
inputs.flake-parts.lib.mkFlake { inherit inputs; } {
|
||||
imports = [ inputs.flake-parts.flakeModules.modules ];
|
||||
systems = [ "x86_64-linux" ];
|
||||
perSystem =
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
packages.default = pkgs.hello;
|
||||
};
|
||||
};
|
||||
outputs = inputs: inputs.flake-parts.lib.mkFlake { inherit inputs; } (inputs.import-tree ./modules);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue