Skip to content

Commit f4b0df1

Browse files
committed
docs(install): serve install.sh via github pages and update references
1 parent 5aa4628 commit f4b0df1

7 files changed

Lines changed: 175 additions & 169 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
The fastest way to bootstrap a new project or integrate the framework into an existing one is to run the following command in your terminal:
2323

2424
```bash
25-
curl -fsSL https://raw.githubusercontent.com/apiad/starter/main/install.sh | bash
25+
curl -fsSL https://apiad.github.io/starter/install.sh | bash
2626
```
2727

2828
This interactive script will:

TASKS.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,10 @@ Put done tasks into the Archive.
1818

1919
---
2020

21-
## Archive
22-
- [x] Create comprehensive User Guide (`docs/user-guide.md`) based on "The Architect in the Machine" philosophy. (2026-03-11) (See plan: plans/user-guide-integration.md)
21+
## Archive
22+
+- [x] Update `install.sh` to be served via GitHub Pages and update all references to use the new URL. (2026-03-11)
23+
- [x] Create comprehensive User Guide (`docs/user-guide.md`) based on "The Architect in the Machine" philosophy. (2026-03-11) (See plan: plans/user-guide-integration.md)
24+
2325
- [x] Refine `/plan` command to strictly enforce a non-execution mandate for generated plans. (2026-03-11)
2426
- [x] Integrate MkDocs with Material theme and setup automatic GitHub Pages deployment via CI/CD. (2026-03-11) (See plan: plans/mkdocs-integration.md)
2527
- [x] Create comprehensive project documentation in `docs/` (Overview, Deployment, Design, Development). (2026-03-11)

docs/deploy.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Getting the **Gemini CLI Opinionated Framework** up and running is an automated,
77
The fastest way to install or update the framework is to run the following command:
88

99
```bash
10-
curl -fsSL https://raw.githubusercontent.com/apiad/starter/main/install.sh | bash
10+
curl -fsSL https://apiad.github.io/starter/install.sh | bash
1111
```
1212

1313
### 1. New Project (Scaffolding)

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ The `makefile` is the ultimate source of truth for project health. Automated hoo
2222
The fastest way to bootstrap a new project or integrate the framework into an existing one is to run the following command in your terminal:
2323

2424
```bash
25-
curl -fsSL https://raw.githubusercontent.com/apiad/starter/main/install.sh | bash
25+
curl -fsSL https://apiad.github.io/starter/install.sh | bash
2626
```
2727

2828
!!! success "Next Steps"

docs/install.sh

Lines changed: 165 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,165 @@
1+
#!/bin/bash
2+
set -e
3+
4+
# --- Configuration ---
5+
REPO_URL="https://github.com/apiad/starter.git"
6+
VERSION="0.11.0"
7+
8+
# --- Functions ---
9+
banner() {
10+
echo -e "\033[1;34m"
11+
echo " ____ _ _ "
12+
echo " / ___| ___ _ __ ___ (_) __ (_)"
13+
echo "| | _ / _ \ '_ \' _ \ | '_ \| |"
14+
echo "| |_| | __/ | | | | | | | | | |"
15+
echo " \____|\___|_| |_| |_|_|_| |_|_|"
16+
echo -e "\033[0m"
17+
echo -e "\033[1;32m Gemini CLI Starter v$VERSION\033[0m"
18+
echo "------------------------------------------"
19+
}
20+
21+
error() {
22+
echo -e "\033[0;31m❌ Error: $1\033[0m" >&2
23+
exit 1
24+
}
25+
26+
confirm() {
27+
echo -n "$1 [y/N]: "
28+
read CONFIRM < /dev/tty
29+
if [[ ! "$CONFIRM" =~ ^[Yy]$ ]]; then
30+
echo "Aborted by user."
31+
exit 0
32+
fi
33+
}
34+
35+
# --- Check Prerequisites ---
36+
for cmd in git node; do
37+
if ! command -v "$cmd" >/dev/null 2>&1; then
38+
error "$cmd is not installed. Please install it and try again."
39+
fi
40+
done
41+
42+
# --- Git Environment Validation ---
43+
if ! git rev-parse --is-inside-work-tree >/dev/null 2>&1; then
44+
echo "📂 Initializing git repository..."
45+
git init -q
46+
fi
47+
48+
if [[ -n $(git status --porcelain) ]]; then
49+
error "Working tree is not clean. Please commit or stash your changes before running this script."
50+
fi
51+
52+
# --- Inputs ---
53+
banner
54+
55+
# --- Acquisition ---
56+
echo "🚀 Fetching latest framework from $REPO_URL..."
57+
TEMP_DIR=$(mktemp -d)
58+
trap 'rm -rf "$TEMP_DIR"' EXIT
59+
60+
git clone --depth 1 -q "$REPO_URL" "$TEMP_DIR" || error "Failed to clone template repository."
61+
62+
# --- Discovery ---
63+
FILES_TO_EXTRACT=(
64+
"GEMINI.md"
65+
"makefile"
66+
"TASKS.md"
67+
"CHANGELOG.md"
68+
"README.md"
69+
)
70+
71+
CONTENT_DIRS=(
72+
"journal"
73+
"plans"
74+
"research"
75+
"drafts"
76+
)
77+
78+
WILL_CREATE=()
79+
WILL_UPDATE=()
80+
81+
# Check .gemini directory
82+
if [[ -d ".gemini" ]]; then
83+
WILL_UPDATE+=(".gemini/ (core framework)")
84+
else
85+
WILL_CREATE+=(".gemini/ (core framework)")
86+
fi
87+
88+
# Check top-level files
89+
for f in "${FILES_TO_EXTRACT[@]}"; do
90+
if [[ -e "$f" ]]; then
91+
WILL_UPDATE+=("$f")
92+
else
93+
WILL_CREATE+=("$f")
94+
fi
95+
done
96+
97+
# Check content directories
98+
for d in "${CONTENT_DIRS[@]}"; do
99+
if [[ ! -d "$d" ]]; then
100+
WILL_CREATE+=("$d/")
101+
fi
102+
done
103+
104+
# --- Summary & Confirmation ---
105+
echo -e "\033[1;33mProposed Changes:\033[0m"
106+
if [[ ${#WILL_CREATE[@]} -gt 0 ]]; then
107+
echo -e "\033[1;32mNew files/folders to create:\033[0m"
108+
for f in "${WILL_CREATE[@]}"; do echo " + $f"; done
109+
fi
110+
111+
if [[ ${#WILL_UPDATE[@]} -gt 0 ]]; then
112+
echo -e "\033[1;34mExisting files/folders to update (framework only):\033[0m"
113+
for f in "${WILL_UPDATE[@]}"; do echo " ~ $f"; done
114+
fi
115+
116+
echo ""
117+
confirm "Do you want to proceed with these changes?"
118+
119+
# --- Execution ---
120+
IS_UPDATE=false
121+
if [[ -d ".gemini" ]]; then
122+
IS_UPDATE=true
123+
fi
124+
125+
echo "🛠️ Applying changes..."
126+
127+
# 1. Update .gemini (non-destructive for user files)
128+
mkdir -p .gemini
129+
cp -r "$TEMP_DIR/.gemini/." .gemini/
130+
131+
# 2. Update Top-Level Files
132+
for f in "${FILES_TO_EXTRACT[@]}"; do
133+
cp "$TEMP_DIR/$f" .
134+
done
135+
136+
# 3. Ensure Content Directories & .gitkeep
137+
for d in "${CONTENT_DIRS[@]}"; do
138+
mkdir -p "$d"
139+
if [[ -f "$TEMP_DIR/$d/.gitkeep" ]]; then
140+
cp "$TEMP_DIR/$d/.gitkeep" "$d/"
141+
fi
142+
done
143+
144+
# 4. Journal Entry
145+
TODAY=$(date +%Y-%m-%d)
146+
mkdir -p journal
147+
JOURNAL_FILE="journal/$TODAY.md"
148+
if [[ ! -f "$JOURNAL_FILE" ]]; then
149+
echo "# $TODAY" > "$JOURNAL_FILE"
150+
fi
151+
152+
if $IS_UPDATE; then
153+
echo -e "\n## Gemini CLI Update\n- Updated framework to version $VERSION." >> "$JOURNAL_FILE"
154+
COMMIT_MSG="chore: update Gemini CLI framework to v$VERSION"
155+
else
156+
echo -e "\n## Gemini CLI Integration\n- Integrated Gemini CLI framework v$VERSION." >> "$JOURNAL_FILE"
157+
COMMIT_MSG="feat: integrate Gemini CLI framework v$VERSION"
158+
fi
159+
160+
# --- Post-Install ---
161+
git add .
162+
git commit -m "$COMMIT_MSG" -q
163+
164+
echo "✅ Gemini CLI framework $( [ "$IS_UPDATE" = true ] && echo "updated" || echo "integrated" ) successfully!"
165+
echo "🚀 Run 'gemini /onboard' to get started!"

install.sh

Lines changed: 1 addition & 164 deletions
Original file line numberDiff line numberDiff line change
@@ -1,165 +1,2 @@
11
#!/bin/bash
2-
set -e
3-
4-
# --- Configuration ---
5-
REPO_URL="https://github.com/apiad/starter.git"
6-
VERSION="0.11.0"
7-
8-
# --- Functions ---
9-
banner() {
10-
echo -e "\033[1;34m"
11-
echo " ____ _ _ "
12-
echo " / ___| ___ _ __ ___ (_) __ (_)"
13-
echo "| | _ / _ \ '_ \' _ \ | '_ \| |"
14-
echo "| |_| | __/ | | | | | | | | | |"
15-
echo " \____|\___|_| |_| |_|_|_| |_|_|"
16-
echo -e "\033[0m"
17-
echo -e "\033[1;32m Gemini CLI Starter v$VERSION\033[0m"
18-
echo "------------------------------------------"
19-
}
20-
21-
error() {
22-
echo -e "\033[0;31m❌ Error: $1\033[0m" >&2
23-
exit 1
24-
}
25-
26-
confirm() {
27-
echo -n "$1 [y/N]: "
28-
read CONFIRM < /dev/tty
29-
if [[ ! "$CONFIRM" =~ ^[Yy]$ ]]; then
30-
echo "Aborted by user."
31-
exit 0
32-
fi
33-
}
34-
35-
# --- Check Prerequisites ---
36-
for cmd in git node; do
37-
if ! command -v "$cmd" >/dev/null 2>&1; then
38-
error "$cmd is not installed. Please install it and try again."
39-
fi
40-
done
41-
42-
# --- Git Environment Validation ---
43-
if ! git rev-parse --is-inside-work-tree >/dev/null 2>&1; then
44-
echo "📂 Initializing git repository..."
45-
git init -q
46-
fi
47-
48-
if [[ -n $(git status --porcelain) ]]; then
49-
error "Working tree is not clean. Please commit or stash your changes before running this script."
50-
fi
51-
52-
# --- Inputs ---
53-
banner
54-
55-
# --- Acquisition ---
56-
echo "🚀 Fetching latest framework from $REPO_URL..."
57-
TEMP_DIR=$(mktemp -d)
58-
trap 'rm -rf "$TEMP_DIR"' EXIT
59-
60-
git clone --depth 1 -q "$REPO_URL" "$TEMP_DIR" || error "Failed to clone template repository."
61-
62-
# --- Discovery ---
63-
FILES_TO_EXTRACT=(
64-
"GEMINI.md"
65-
"makefile"
66-
"TASKS.md"
67-
"CHANGELOG.md"
68-
"README.md"
69-
)
70-
71-
CONTENT_DIRS=(
72-
"journal"
73-
"plans"
74-
"research"
75-
"drafts"
76-
)
77-
78-
WILL_CREATE=()
79-
WILL_UPDATE=()
80-
81-
# Check .gemini directory
82-
if [[ -d ".gemini" ]]; then
83-
WILL_UPDATE+=(".gemini/ (core framework)")
84-
else
85-
WILL_CREATE+=(".gemini/ (core framework)")
86-
fi
87-
88-
# Check top-level files
89-
for f in "${FILES_TO_EXTRACT[@]}"; do
90-
if [[ -e "$f" ]]; then
91-
WILL_UPDATE+=("$f")
92-
else
93-
WILL_CREATE+=("$f")
94-
fi
95-
done
96-
97-
# Check content directories
98-
for d in "${CONTENT_DIRS[@]}"; do
99-
if [[ ! -d "$d" ]]; then
100-
WILL_CREATE+=("$d/")
101-
fi
102-
done
103-
104-
# --- Summary & Confirmation ---
105-
echo -e "\033[1;33mProposed Changes:\033[0m"
106-
if [[ ${#WILL_CREATE[@]} -gt 0 ]]; then
107-
echo -e "\033[1;32mNew files/folders to create:\033[0m"
108-
for f in "${WILL_CREATE[@]}"; do echo " + $f"; done
109-
fi
110-
111-
if [[ ${#WILL_UPDATE[@]} -gt 0 ]]; then
112-
echo -e "\033[1;34mExisting files/folders to update (framework only):\033[0m"
113-
for f in "${WILL_UPDATE[@]}"; do echo " ~ $f"; done
114-
fi
115-
116-
echo ""
117-
confirm "Do you want to proceed with these changes?"
118-
119-
# --- Execution ---
120-
IS_UPDATE=false
121-
if [[ -d ".gemini" ]]; then
122-
IS_UPDATE=true
123-
fi
124-
125-
echo "🛠️ Applying changes..."
126-
127-
# 1. Update .gemini (non-destructive for user files)
128-
mkdir -p .gemini
129-
cp -r "$TEMP_DIR/.gemini/." .gemini/
130-
131-
# 2. Update Top-Level Files
132-
for f in "${FILES_TO_EXTRACT[@]}"; do
133-
cp "$TEMP_DIR/$f" .
134-
done
135-
136-
# 3. Ensure Content Directories & .gitkeep
137-
for d in "${CONTENT_DIRS[@]}"; do
138-
mkdir -p "$d"
139-
if [[ -f "$TEMP_DIR/$d/.gitkeep" ]]; then
140-
cp "$TEMP_DIR/$d/.gitkeep" "$d/"
141-
fi
142-
done
143-
144-
# 4. Journal Entry
145-
TODAY=$(date +%Y-%m-%d)
146-
mkdir -p journal
147-
JOURNAL_FILE="journal/$TODAY.md"
148-
if [[ ! -f "$JOURNAL_FILE" ]]; then
149-
echo "# $TODAY" > "$JOURNAL_FILE"
150-
fi
151-
152-
if $IS_UPDATE; then
153-
echo -e "\n## Gemini CLI Update\n- Updated framework to version $VERSION." >> "$JOURNAL_FILE"
154-
COMMIT_MSG="chore: update Gemini CLI framework to v$VERSION"
155-
else
156-
echo -e "\n## Gemini CLI Integration\n- Integrated Gemini CLI framework v$VERSION." >> "$JOURNAL_FILE"
157-
COMMIT_MSG="feat: integrate Gemini CLI framework v$VERSION"
158-
fi
159-
160-
# --- Post-Install ---
161-
git add .
162-
git commit -m "$COMMIT_MSG" -q
163-
164-
echo "✅ Gemini CLI framework $( [ "$IS_UPDATE" = true ] && echo "updated" || echo "integrated" ) successfully!"
165-
echo "🚀 Run 'gemini /onboard' to get started!"
2+
exec "$(dirname "$0")/docs/install.sh" "$@"

journal/2026-03-11.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,5 @@
1212
- Verified the MkDocs build locally using `uv run` and added the `site/` directory to `.gitignore`.
1313
- Created a comprehensive User Guide (`docs/user-guide.md`) based on "The Architect in the Machine" philosophy and integrated it into the MkDocs navigation.
1414
- Refined the `/plan` command to strictly enforce a non-execution mandate, ensuring plans are only analyzed, verified, and saved.
15+
- Moved `install.sh` to `docs/install.sh` and replaced the root file with a wrapper script to ensure it is served via GitHub Pages at `https://apiad.github.io/starter/install.sh`.
16+
- Updated all documentation and README references to use the new GitHub Pages URL for the installation script.

0 commit comments

Comments
 (0)