mirror of
https://github.com/TagStudioDev/TagStudio.git
synced 2026-02-13 21:26:20 +00:00
feat(flake): remove impurity, update nix-direnv
Use path as an input that can be overriden automatically when direnv is in use. nix-direnv version present in .envrc has been updated, using watch_file on the flake is already handled.
This commit is contained in:
11
.envrc
11
.envrc
@@ -1,10 +1,9 @@
|
||||
if ! has nix_direnv_version || ! nix_direnv_version 2.2.1; then
|
||||
source_url 'https://raw.githubusercontent.com/nix-community/nix-direnv/2.2.1/direnvrc' 'sha256-zelF0vLbEl5uaqrfIzbgNzJWGmLzCmYAkInj/LNxvKs='
|
||||
if ! has nix_direnv_version || ! nix_direnv_version 3.0.5; then
|
||||
source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/3.0.5/direnvrc" "sha256-RuwIS+QKFj/T9M2TFXScjBsLR6V3A17YVoEW/Q6AZ1w="
|
||||
fi
|
||||
|
||||
watch_file flake.nix
|
||||
watch_file flake.lock
|
||||
|
||||
if ! use flake . --impure; then
|
||||
DEVENV_ROOT_FILE="$(mktemp)"
|
||||
printf %s "${PWD}" > "${DEVENV_ROOT_FILE}"
|
||||
if ! use flake . --override-input devenv-root "file+file://${DEVENV_ROOT_FILE}"; then
|
||||
printf '%s\n' "devenv could not be built. The devenv environment was not loaded. Make the necessary changes to devenv.nix and hit enter to try again." >&2
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user