home

My NixOS systems configurations.
Log | Files | Refs | LICENSE

commit 7e2ddb2f17f395a719b00eaca10ab81c62d4082f
parent 487c720309446d7e5731a51ceef5c0e3f15d3bcc
Author: Vincent Demeester <vincent@sbr.pm>
Date:   Fri, 25 Feb 2022 17:50:40 +0100

systems: enable lorri…

… and switch to using it. Mainly, it reduces the time direnv takes at
the initial loading of the shell.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>

Diffstat:
M.envrc | 12+-----------
Mshell.nix | 4++++
Msystems/modules/profiles/dev.nix | 1+
Musers/vincent/dev/src/osp.envrc | 5+----
Musers/vincent/dev/src/tektoncd.envrc | 7+------
Musers/vincent/dev/src/tektoncd.shell.nix | 1+
6 files changed, 9 insertions(+), 21 deletions(-)

diff --git a/.envrc b/.envrc @@ -1,11 +1 @@ -use_nix shell.nix - -watch_file ./shell.nix -watch_file ./default.nix -watch_file ./nix/sources.json -watch_file ./nix/default.nix - -test -f .secrets && source .secrets || echo "no secrets" -export QEMU_OPTS="-m 8096 -cpu host" -export PATH="${PWD}/bin:${PATH}" -export REPO_ROOT="${PWD}" +eval "$(lorri direnv)" diff --git a/shell.nix b/shell.nix @@ -23,5 +23,9 @@ pkgs.mkShell ]; shellHook = '' export NIX_PATH="nixpkgs=${pkgs.path}:nixos=${nixos.path}:nixos-unstable=${nixos-unstable.path}" + test -f .secrets && source .secrets || echo "no secrets" + export QEMU_OPTS="-m 8096 -cpu host" + export PATH="$(pwd)/bin:$PATH" + export REPO_ROOT="$(pwd)" ''; } diff --git a/systems/modules/profiles/dev.nix b/systems/modules/profiles/dev.nix @@ -12,6 +12,7 @@ in }; config = mkIf cfg.enable { profiles.git.enable = true; + services.lorri.enable = true; environment.systemPackages = with pkgs; [ git tig diff --git a/users/vincent/dev/src/osp.envrc b/users/vincent/dev/src/osp.envrc @@ -1,4 +1 @@ -use_nix -watch_file shell.nix -watch_file /etc/nixos/nix/sources.json -watch_file /etc/nixos/nix/default.nix +eval "$(lorri direnv)" diff --git a/users/vincent/dev/src/tektoncd.envrc b/users/vincent/dev/src/tektoncd.envrc @@ -1,6 +1 @@ -export KO_DOCKER_REPO=gcr.io/vde-tekton - -use_nix -watch_file shell.nix -watch_file /etc/nixos/nix/sources.json -watch_file /etc/nixos/nix/default.nix +eval "$(lorri direnv)" diff --git a/users/vincent/dev/src/tektoncd.shell.nix b/users/vincent/dev/src/tektoncd.shell.nix @@ -22,5 +22,6 @@ pkgs.mkShell { export GOMAXPROCS=8 export KUSTOMIZE_BIN=${pkgs.kustomize}/bin/kustomize export KO_BIN=${my.ko}/bin/ko + export KO_DOCKER_REPO=gcr.io/vde-tekton ''; }