feat: move to a flake-parts based flake where templates import flake modules from the root flake
This commit is contained in:
@@ -1,12 +1,27 @@
|
||||
{
|
||||
description = "A collection of templates for various programming languages";
|
||||
|
||||
outputs = {self}: {
|
||||
templates = {
|
||||
rust = {
|
||||
path = ./rust;
|
||||
description = "A rust flake with crane and templates for command args and configs";
|
||||
};
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
|
||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
|
||||
treefmt-nix = {
|
||||
url = "github:numtide/treefmt-nix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
crane.url = "github:ipetkov/crane";
|
||||
};
|
||||
|
||||
outputs = {flake-parts, ...} @ inputs:
|
||||
flake-parts.lib.mkFlake {inherit inputs;} {
|
||||
imports = [
|
||||
./rust.nix
|
||||
];
|
||||
|
||||
systems = ["aarch64-linux" "x86_64-linux" "aarch64-darwin" "x86_64-darwin"];
|
||||
|
||||
perSystem = {pkgs, ...}: {formatter = pkgs.alejandra;};
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user