add possibility to add multiple templates

This commit is contained in:
Jörg Thalheim 2022-06-01 09:29:58 +02:00
parent 59040df378
commit 023f8af588
No known key found for this signature in database
5 changed files with 10 additions and 6 deletions

4
templates/flake/.envrc Normal file
View file

@ -0,0 +1,4 @@
if ! has nix_direnv_version || ! nix_direnv_version 2.1.0; then
source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/2.1.0/direnvrc" "sha256-FAT2R9yYvVg516v3LiogjIc8YfsbWbMM/itqWsm5xTA="
fi
use flake

15
templates/flake/flake.nix Normal file
View file

@ -0,0 +1,15 @@
{
description = "A basic flake with a shell";
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
inputs.flake-utils.url = "github:numtide/flake-utils";
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system: let
pkgs = nixpkgs.legacyPackages.${system};
in {
devShell = pkgs.mkShell {
nativeBuildInputs = [ pkgs.bashInteractive ];
buildInputs = [ ];
};
});
}