fix: setup.sh and install.sh improvements (#155)
- setup.sh: Skip git init if .git already exists (prevents errors in existing repos) - install.sh: Copy setup.sh directly instead of hardcoding a simplified version This ensures global installation uses the same setup logic as local, including .ralphrc generation via enable_core.sh Co-authored-by: dawenrenhub <darwinren321@gmail.com>
This commit is contained in:
parent
627ad7d9a5
commit
48ba86a2de
2 changed files with 13 additions and 45 deletions
6
setup.sh
6
setup.sh
|
|
@ -92,8 +92,10 @@ CB_OUTPUT_DECLINE_THRESHOLD=70
|
|||
RALPHRCEOF
|
||||
fi
|
||||
|
||||
# Initialize git
|
||||
git init
|
||||
# Initialize git (skip if already initialized)
|
||||
if [[ ! -d ".git" ]]; then
|
||||
git init
|
||||
fi
|
||||
echo "# $PROJECT_NAME" > README.md
|
||||
git add .
|
||||
git commit -m "Initial Ralph project setup"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue