peppa/scripts/lib/ci-env.sh
Асель 56a7756e71 PEP-22: scripts/ci.sh, PR status peppa/ci, mock-act-runner
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-13 15:00:28 +05:00

7 lines
324 B
Bash

# Loads .env for the CI scripts: this checkout's, else the main checkout's (worktrees have none).
_ci_env="$ROOT/.env"
[ -f "$_ci_env" ] || _ci_env="$(dirname "$(git -C "$ROOT" rev-parse --path-format=absolute --git-common-dir)")/.env"
[ -f "$_ci_env" ] && set -a && . "$_ci_env" && set +a
ENV_FILE="$_ci_env"
unset _ci_env