- scripts/.env 存储敏感配置(已加入 .gitignore) - start_dev_agent.sh 启动时自动 source .env - 环境变量仍可作为 fallback Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -11,3 +11,4 @@ dist/
|
|||||||
*.jpg
|
*.jpg
|
||||||
acceptance-report.json
|
acceptance-report.json
|
||||||
ir_final.json
|
ir_final.json
|
||||||
|
scripts/.env
|
||||||
|
|||||||
@@ -4,6 +4,12 @@
|
|||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
# Source local secrets if available (not tracked by git)
|
||||||
|
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||||
|
if [ -f "$SCRIPT_DIR/.env" ]; then
|
||||||
|
source "$SCRIPT_DIR/.env"
|
||||||
|
fi
|
||||||
|
|
||||||
# Load from environment or default values
|
# Load from environment or default values
|
||||||
export GITEA_API_TOKEN="${GITEA_API_TOKEN:-}"
|
export GITEA_API_TOKEN="${GITEA_API_TOKEN:-}"
|
||||||
export GITEA_URL="${GITEA_URL:-http://localhost:3000}"
|
export GITEA_URL="${GITEA_URL:-http://localhost:3000}"
|
||||||
|
|||||||
Reference in New Issue
Block a user