Skip to content

Commit deaa0d5

Browse files
committed
fix(start.sh): use LPB_DEVCONTAINER_WORKSPACE_DIR as PROJECT_DIR (lpb.py source of truth)
1 parent 1cff21a commit deaa0d5

1 file changed

Lines changed: 6 additions & 9 deletions

File tree

support/start.sh

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -182,15 +182,12 @@ if [[ -n "$ENV_FILE" ]]; then
182182
fi
183183

184184
# ─── 2b. RESOLVE PROJECT DIRECTORY (working dir) ────────────────────────────
185-
# The actual working directory is the project subdir that holds the .env
186-
# (e.g. "/home/lpb/workspace/devstack"), not the workspace root. This is
187-
# where Pi / shell / editor should start. Falls back to WORKSPACE_DIR if no
188-
# .env is found.
189-
190-
PROJECT_DIR="${WORKSPACE_DIR}"
191-
if [[ -n "$ENV_FILE" && -d "$(dirname "$ENV_FILE")" ]]; then
192-
PROJECT_DIR="$(dirname "$ENV_FILE")"
193-
fi
185+
# The project directory is provided by lpb.py via LPB_DEVCONTAINER_WORKSPACE_DIR,
186+
# which is set to the container mount path (e.g. "/home/lpb/workspace/devstack").
187+
# This is the canonical project identity — lpb.py passes the user's chosen path.
188+
# No need to infer from .env location; lpb.py already resolved it correctly.
189+
190+
PROJECT_DIR="${LPB_DEVCONTAINER_WORKSPACE_DIR}"
194191
export PROJECT_DIR
195192
debug "PROJECT_DIR=$PROJECT_DIR"
196193

0 commit comments

Comments
 (0)