From 5a94a69786f50efe98ca659562c22fc60cc819d0 Mon Sep 17 00:00:00 2001 From: Evie Litherland-Smith Date: Mon, 22 May 2023 10:39:40 +0100 Subject: [PATCH] Move setting of venv prompt in template --- templates/python39/shell.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/python39/shell.nix b/templates/python39/shell.nix index 5b62f0fd..23028e5f 100644 --- a/templates/python39/shell.nix +++ b/templates/python39/shell.nix @@ -3,7 +3,7 @@ pkgs.mkShell { nativeBuildInputs = with pkgs; [python39 poetry git]; shellHook = '' export PROJECT_NAME=$(basename $(readlink -f .)) - [ -e .venv/bin/python3 ] && VENV_FLAG="--upgrade" || VENV_FLAG="--clear --prompt $PROJECT_NAME"; python3 -m venv $VENV_FLAG .venv + [ -e .venv/bin/python3 ] && VENV_FLAG="--upgrade" || VENV_FLAG="--clear"; python3 -m venv --prompt $PROJECT_NAME $VENV_FLAG .venv [ -e .venv/bin/activate ] && source .venv/bin/activate ''; }