Skip to content

Commit 46bf715

Browse files
committed
feat(devenv): allow disabling devenv locally with .envrc.user
Current devenv config has problems on at least Ubuntu 22.04. .envrc.user with the below content enables work without devenv: layout_poetry() { # create venv if it doesn't exist poetry run true export VIRTUAL_ENV=$(poetry env info --path) export POETRY_ACTIVE=1 PATH_add "$VIRTUAL_ENV/bin" } layout_poetry export SKIP=nixpkgs-fmt export UNBLOB_USE_DEVENV=false
1 parent 569e0db commit 46bf715

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

.envrc

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
1-
watch_file flake.nix flake.lock devenv.nix
2-
use nix \
3-
--option extra-substituters "https://unblob.cachix.org" \
4-
--option extra-trusted-public-keys "unblob.cachix.org-1:5kWA6DwOg176rSqU8TOTBXWxsDB4LoCMfGfTgL5qCAE="
1+
# Source further custom features from .env.user if exists
2+
# Also allows users to disable/override features in this file
3+
source_env_if_exists .envrc.user
4+
5+
if ${UNBLOB_USE_DEVENV:-true}; then
6+
watch_file flake.nix flake.lock devenv.nix
7+
use nix \
8+
--option extra-substituters "https://unblob.cachix.org" \
9+
--option extra-trusted-public-keys "unblob.cachix.org-1:5kWA6DwOg176rSqU8TOTBXWxsDB4LoCMfGfTgL5qCAE="
10+
fi

0 commit comments

Comments
 (0)