Skip to content

Commit 9296157

Browse files
committed
Add setup wizard, CI workflow, and a why-section in the README
'glaze-dev setup' walks through the whole installation - machine, Glaze, bundled Node, Claude Code, linked skills, plugin, Raycast - explains the four AI engines apps can offer their users, and points at the next step wherever something is missing. It runs without Glaze installed too, so it can guide from zero. install.sh offers to run it at the end. CI (GitHub Actions, macOS runner) syntax-checks every shell script, scans tracked files for smart punctuation, verifies skill frontmatter, and validates the plugin manifest on each push and pull request. README leads with what the project actually gives you: free development on your own Claude subscription, apps whose users choose whether AI costs anything, takeover of interrupted Glaze agent work including the paused queue, and support for other coding agents.
1 parent b05fdc1 commit 9296157

4 files changed

Lines changed: 172 additions & 2 deletions

File tree

.github/workflows/ci.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
jobs:
9+
checks:
10+
runs-on: macos-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
14+
- name: Syntax-check shell scripts
15+
run: |
16+
zsh -n install.sh
17+
zsh -n plugins/glaze-coder/scripts/glaze-dev
18+
zsh -n plugins/glaze-coder/scripts/terminal-launch.sh
19+
for f in plugins/glaze-coder/scripts/raycast/*.sh; do zsh -n "$f"; done
20+
21+
- name: Typography scan (plain punctuation only)
22+
run: |
23+
git ls-files -z | tr '\0' '\n' | grep -vE '\.(png|gif|ico|icns)$' > /tmp/files.txt
24+
perl -CSD -ne 'if (/[\x{2014}\x{2013}\x{2026}\x{201C}\x{201D}\x{2018}\x{2019}\x{00A0}]/) { print "$ARGV:$.: smart punctuation\n"; $bad = 1 } END { exit 1 if $bad }' $(cat /tmp/files.txt)
25+
26+
- name: Skills have frontmatter
27+
run: |
28+
for f in plugins/glaze-coder/skills/*/SKILL.md; do
29+
head -1 "$f" | grep -q '^---$' || { echo "Missing frontmatter: $f"; exit 1; }
30+
done
31+
32+
- name: Plugin manifest is valid JSON
33+
run: python3 -m json.tool plugins/glaze-coder/.claude-plugin/plugin.json > /dev/null

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,23 @@ Node runtime Glaze already ships. Editing and building cost you nothing in Glaze
1414
![macOS](https://img.shields.io/badge/macOS-Tahoe%2B-black)
1515
![Apple Silicon](https://img.shields.io/badge/Apple%20Silicon-required-black)
1616
![License](https://img.shields.io/badge/license-MIT-green)
17+
![CI](https://github.com/GaimsDevSoftware/glaze-coder/actions/workflows/ci.yml/badge.svg)
18+
19+
## Why glaze-coder
20+
21+
- **Development costs 0 Glaze credits.** Glaze's built-in agent spends credits for
22+
every change. glaze-coder does the same work with the Claude subscription you
23+
already pay for: create, code, build and run apps for free.
24+
- **Your app users choose whether AI costs them anything.** Apps built with
25+
glaze-coder ship with an engine picker: built-in Glaze AI (their credits), a free
26+
Google Gemini key, OpenRouter free models, or their own Claude subscription via
27+
the local CLI. When Glaze credits run out, the app switches to a configured free
28+
engine on its own.
29+
- **Pick up where Glaze's agent stopped.** Ran out of credits mid-task? Continue in
30+
Claude Code with full project context, and pull the paused prompt queue straight
31+
out of the Glaze window with `glaze-dev queue`.
32+
- **Not locked to one agent.** Works with codex, opencode, gemini and the desktop
33+
apps too.
1734

1835
## What you get
1936

@@ -55,6 +72,13 @@ Then create your first app and jump straight into Claude Code:
5572
glaze-dev start "Habit Tracker"
5673
```
5774

75+
The installer ends with a guided check of the whole setup. You can rerun it any
76+
time to see what is installed, what is missing, and what to do next:
77+
78+
```bash
79+
glaze-dev setup
80+
```
81+
5882
That is all most people need. The sections below show the individual methods if you
5983
prefer to do it by hand.
6084

@@ -110,6 +134,8 @@ glaze-dev run <app> Open the built app
110134
glaze-dev br <app> Build then run
111135
glaze-dev rm <app> Remove an app (bundle, source, profile)
112136
glaze-dev agents List the coding agents you have installed
137+
glaze-dev setup Guided check of the whole setup
138+
glaze-dev queue <app> Read the paused prompt queue out of the Glaze window
113139
```
114140

115141
`<app>` matches on the folder name or product name, so partial names work.

install.sh

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,17 @@ else
145145
fi
146146
print ""
147147

148+
# 6. Guided check of the whole setup (Glaze, Claude Code, skills, AI engines).
149+
print ""
150+
if [[ -t 0 ]]; then
151+
if ask y "Run the setup check now? (verifies Glaze, Claude Code and the AI engines)"; then
152+
"$HOME/.local/bin/glaze-dev" setup || true
153+
fi
154+
else
155+
print "Tip: run 'glaze-dev setup' for a guided check of the whole setup."
156+
fi
157+
158+
print ""
148159
green "Done."
149160
print "Start a new app now:"
150161
print ' glaze-dev start "My App"'

plugins/glaze-coder/scripts/glaze-dev

Lines changed: 102 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,14 @@ if [[ -z "$GLAZE_BASE" ]]; then
2727
done
2828
fi
2929
if [[ -z "$GLAZE_BASE" || ! -d "$GLAZE_BASE/apps" ]]; then
30-
print -u2 "❌ Fant ikke Glaze. Sett GLAZE_BASE manuelt, eller start Glaze én gang."
31-
exit 1
30+
# setup/help skal kunne veilede selv uten Glaze installert.
31+
case "${1:-}" in
32+
setup|doctor|help|-h|--help|"") GLAZE_BASE="" ;;
33+
*)
34+
print -u2 "❌ Fant ikke Glaze. Sett GLAZE_BASE manuelt, eller start Glaze én gang."
35+
print -u2 " Ny her? Kjør: glaze-dev setup"
36+
exit 1 ;;
37+
esac
3238
fi
3339

3440
APPS_DIR="$GLAZE_BASE/apps"
@@ -207,6 +213,98 @@ cmd_buildrun(){ cmd_build "$1"; cmd_run "$1"; }
207213
cmd_path() { _need "$1"; print -r -- "$SRC"; }
208214
cmd_finder() { _need "$1"; open "$SRC"; }
209215

216+
# Interaktiv onboarding og helsesjekk: verifiser hele oppsettet steg for steg,
217+
# forklar AI-motorvalgene, og pek på neste steg der noe mangler. Trygg å kjøre
218+
# når som helst; endrer ingenting uten å spørre.
219+
cmd_setup() {
220+
local pass="%F{green}✓%f" fail="%F{red}✗%f" note="%F{yellow}!%f"
221+
print -P "%B== glaze-dev setup: onboarding og helsesjekk ==%b"
222+
print ""
223+
224+
# 1) Maskin
225+
if [[ "$(uname -m)" == arm64 ]]; then
226+
print -P "$pass Apple Silicon-Mac"
227+
else
228+
print -P "$fail Krever Apple Silicon (arm64). Denne maskinen: $(uname -m)"
229+
fi
230+
231+
# 2) Glaze selv
232+
if [[ -n "$GLAZE_BASE" && -d "$GLAZE_BASE/apps" ]]; then
233+
local napps; napps="$(ls -1 "$APPS_DIR" 2>/dev/null | wc -l | tr -d ' ')"
234+
print -P "$pass Glaze er installert ($napps app(er))"
235+
if (( napps == 0 )); then
236+
print " Neste steg: lag din første app -> glaze-dev start \"Min App\""
237+
fi
238+
else
239+
print -P "$fail Glaze er ikke installert (eller aldri startet)."
240+
print " Last ned fra https://www.glaze.app, åpne den én gang, og kjør setup igjen."
241+
print ""
242+
print "Resten av sjekkene hopper vi over til Glaze er på plass."
243+
return 0
244+
fi
245+
246+
# 3) Medfølgende Node (kreves for gratis bygg)
247+
if command -v node >/dev/null 2>&1 && [[ "$(node -v 2>/dev/null)" == v2[4-9]* ]]; then
248+
print -P "$pass Node $(node -v) (Glaze sin medfølgende runtime)"
249+
else
250+
print -P "$note Fant ikke Glaze sin Node >= 24 på PATH. Bygg kan feile."
251+
print " Den følger med Glaze; åpne Glaze én gang så lastes den ned."
252+
fi
253+
254+
# 4) Claude Code (gratis utvikling via ditt abonnement)
255+
if command -v claude >/dev/null 2>&1; then
256+
print -P "$pass Claude Code $(claude --version 2>/dev/null | head -1)"
257+
print " NB: --version beviser ikke innlogging. Aldri logget inn? Kjør: claude"
258+
else
259+
print -P "$fail Claude Code er ikke installert."
260+
print " Installer fra https://claude.com/product/claude-code og kjør 'claude' for innlogging."
261+
print " Uten den koster utvikling Glaze-kreditter; med den er den gratis via abonnementet ditt."
262+
fi
263+
264+
# 5) Glaze-skills lenket inn i ~/.claude
265+
local nlinked=0
266+
[[ -d "$HOME/.claude/skills" ]] && nlinked="$(ls -1 "$HOME/.claude/skills" 2>/dev/null | grep -c "^glaze" || true)"
267+
if (( nlinked > 5 )); then
268+
print -P "$pass Glaze-skills lenket inn i ~/.claude/skills ($nlinked stk)"
269+
else
270+
print -P "$note Glaze-skills ser ikke ut til å være lenket."
271+
if [[ -t 0 ]]; then
272+
read "ans? Lenke dem nå? [Y/n]: "
273+
[[ -z "$ans" || "$ans" == [Yy]* ]] && { _link_skills; print -P "$pass Lenket."; }
274+
else
275+
print " Kjør: glaze-dev skills"
276+
fi
277+
fi
278+
279+
# 6) Claude Code-plugin
280+
if command -v claude >/dev/null 2>&1; then
281+
if claude plugin list 2>/dev/null | grep -q "glaze-coder"; then
282+
print -P "$pass Claude Code-pluginen (/glaze-coder:glaze) er installert"
283+
else
284+
print -P "$note Claude Code-pluginen mangler. Kjør: claude plugin install glaze-coder"
285+
fi
286+
fi
287+
288+
# 7) Raycast (valgfritt)
289+
if [[ -d "/Applications/Raycast.app" || -d "$HOME/Applications/Raycast.app" ]]; then
290+
print -P "$pass Raycast finnes. Kommandoer settes opp med: glaze-dev raycast"
291+
else
292+
print -P "$note Raycast ikke funnet (valgfritt). Kommandoene virker fint uten."
293+
fi
294+
295+
# 8) AI i appene dine
296+
print ""
297+
print -P "%BAI-motorer i appene du bygger:%b"
298+
print " Apper laget med glaze-coder gir sluttbrukeren et valg om AI skal koste noe:"
299+
print " - Glaze AI innebygd, null oppsett, bruker brukerens Glaze-kreditter"
300+
print " - Google Gemini gratis med egen nøkkel (https://aistudio.google.com/apikey)"
301+
print " - OpenRouter gratis modeller med egen nøkkel (lav dagskvote)"
302+
print " - Claude Code gratis via brukerens Claude-abonnement (lokal CLI)"
303+
print " Tomme Glaze-kreditter? Reservemotoren bytter automatisk til en gratis motor."
304+
print ""
305+
print -P "%BKlar. Neste steg:%b glaze-dev start \"Min App\" (ny app + Claude Code, 0 kreditter)"
306+
}
307+
210308
# Les ut koede (pausede) prompts fra Glaze-vibekoderens chatvindu for en app.
211309
# Koen finnes bare i Glaze-UIets minne (ikke i db/localStorage), så vi leser den
212310
# fra accessibility-treet. CSS-avkutting kutter ikke DOM-teksten, så vi får
@@ -442,6 +540,7 @@ ALLE KOMMANDOER:
442540
glaze-dev finder <app> Åpne app-mappen i Finder
443541
glaze-dev rm <app> Fjern app fullstendig (bundle+kilde+profil)
444542
glaze-dev raycast Sett opp Raycast (kopier sti + åpne Raycast)
543+
glaze-dev setup Onboarding/helsesjekk av hele oppsettet
445544
glaze-dev skills Koble Glaze-skills inn i ~/.claude/skills
446545
447546
<app> matcher på mappenavn eller produktnavn (delvis treff er ok).
@@ -471,6 +570,7 @@ case "$cmd" in
471570
finder|reveal) cmd_finder "$@" ;;
472571
rm|delete|remove) cmd_rm "$@" ;;
473572
raycast|raycast-setup) cmd_raycast "$@" ;;
573+
setup|doctor) cmd_setup "$@" ;;
474574
skills|link-skills) cmd_skills ;;
475575
help|-h|--help) cmd_help ;;
476576
*) print -u2 "Ukjent kommando: $cmd"; cmd_help; exit 1 ;;

0 commit comments

Comments
 (0)