diff options
| author | Mike Vink <mike1994vink@gmail.com> | 2023-01-24 15:52:39 +0000 |
|---|---|---|
| committer | Mike Vink <mike1994vink@gmail.com> | 2023-01-24 15:52:39 +0000 |
| commit | dfca95538d690accc8c9068e1aa449d0d027a69a (patch) | |
| tree | c4f661e1563a8f4b7a5073877da36f0b1dcf38db | |
| parent | 687c37c3bf1793256bbb979b4283da2b7425020b (diff) | |
update flake template
| -rw-r--r-- | flake.nix | 5 | ||||
| -rw-r--r-- | home.nix | 2 | ||||
| -rw-r--r-- | templates/flake/.envrc | 4 | ||||
| -rw-r--r-- | templates/flake/flake.nix (renamed from flake-template/flake.nix) | 0 |
4 files changed, 10 insertions, 1 deletions
@@ -50,5 +50,10 @@ home-manager = home-manager; }; }; + + templates.default = { + path = ./templates/flake; + description = "nix flake new -t ~/flake"; + }; }; } @@ -58,7 +58,7 @@ V = "xrandr --output HDMI1 --auto --output eDP1 --off"; v = "xrandr --output eDP1 --auto --output HDMI1 --off"; vV = "xrandr --output eDP1 --auto --output HDMI1 --off"; - newflake = "nix flake new -t github:nix-community/nix-direnv "; + newflake = "nix flake new -t ~/flake "; }; }; diff --git a/templates/flake/.envrc b/templates/flake/.envrc new file mode 100644 index 0000000..1305de8 --- /dev/null +++ b/templates/flake/.envrc @@ -0,0 +1,4 @@ +if ! has nix_direnv_version || ! nix_direnv_version 2.2.0; then + source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/2.2.0/direnvrc" "sha256-5EwyKnkJNQeXrRkYbwwRBcXbibosCJqyIUuz9Xq+LRc=" +fi +use flake diff --git a/flake-template/flake.nix b/templates/flake/flake.nix index bd88f19..bd88f19 100644 --- a/flake-template/flake.nix +++ b/templates/flake/flake.nix |
