From 3c06e98092c8a5a0d677e0c8346adb677d53cac2 Mon Sep 17 00:00:00 2001 From: Denis Parfionovich Date: Sat, 16 May 2026 16:44:26 +0800 Subject: [PATCH] feat(web-install): curl-pipeable bootstrapper at install.keisei.app MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Thin wrapper (88 LOC) that lets a fresh machine install KeiSeiKit with one line, no prior clone: curl -fsSL https://install.keisei.app | bash curl -fsSL https://install.keisei.app | bash -s -- --profile=dev --yes ## Why a third install entry point Existing install path required `git clone` + `cd` + `./bootstrap.sh` — three commands the user has to type, plus they must already have the repo URL handy. For private repos with SSH auth this is real friction. `web-install.sh` is meant to be served as a static file (Cloudflare Pages / nginx) at install.keisei.app. It does ONE thing: prereq → clone → delegate to ./bootstrap.sh. Single source of truth — no duplicated install logic. ## What it does 1. Splash + log to ~/.keisei-install.log 2. Hard prereq: git (the one thing bootstrap.sh cannot self-install) 3. SSH auth probe for git@github.com — clear error message if key missing 4. Clone/pull KeiSeiLab/KeiSeiKit-1.0 to $KEISEI_ROOT (default ~/.local/share/keisei) 5. git submodule update --init (pulls kei-registries) 6. exec ./bootstrap.sh "$@" — pass-through all flags ## Env overrides - KEISEI_ROOT — install location - KEISEI_REPO — git URL - KEISEI_REF — branch/tag/sha ## Hosting Push this file to install.keisei.app (Cloudflare Pages, S3+CF, nginx static — anything that serves a single .sh over HTTPS). ## README updated Quick start section now shows the curl one-liner as the recommended path. Repo URL corrected from KeiSei84 → KeiSeiLab org. Co-Authored-By: Claude Opus 4.7 (1M context) --- README.md | 14 ++++++-- web-install.sh | 88 ++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 100 insertions(+), 2 deletions(-) create mode 100755 web-install.sh diff --git a/README.md b/README.md index 1b1bcfb..a744269 100644 --- a/README.md +++ b/README.md @@ -63,16 +63,26 @@ fork it. ## Quick start ```bash +# Web installer (recommended — one line, no prior clone) +curl -fsSL https://install.keisei.app | bash +curl -fsSL https://install.keisei.app | bash -s -- --profile=dev --yes # CI + # Claude Code (primary target — full hook + agent integration) /plugin marketplace add KeiSei84/KeiSeiKit-1.0 /plugin install keisei@keisei-marketplace # Any MCP-compatible client (Cursor / Continue / Zed / Aider / etc) -git clone https://github.com/KeiSei84/KeiSeiKit-1.0 +git clone https://github.com/KeiSeiLab/KeiSeiKit-1.0 cd KeiSeiKit-1.0 -./install.sh --profile=minimal +./bootstrap.sh # interactive profile picker +# or: ./install.sh --profile=minimal # direct ``` +The web installer (`web-install.sh` in this repo, served at +`install.keisei.app`) is a thin curl-pipeable wrapper that clones the +repo and delegates to `bootstrap.sh` — single source of truth, no +duplicated install logic. + 38 agents + 68 skills + 38 hooks + nightly consolidation wired in ~60 seconds. Twelve install profiles (`outcome-only`, `minimal`, `core`, `frontend`, `ops`, `dev`, `mcp`, `cortex`, `local-mirror`, diff --git a/web-install.sh b/web-install.sh new file mode 100755 index 0000000..cd8ce1d --- /dev/null +++ b/web-install.sh @@ -0,0 +1,88 @@ +#!/usr/bin/env bash +# web-install.sh — curl-pipeable bootstrapper for KeiSeiKit. +# +# Designed to be served as a static file (e.g. install.keisei.app) and run +# from a fresh machine via: +# +# curl -fsSL https://install.keisei.app | bash +# curl -fsSL https://install.keisei.app | bash -s -- --profile=dev --yes +# +# This script's ONLY job is: prereq → clone → delegate to ./bootstrap.sh. +# All real work lives in the kit's existing bootstrap.sh (prereqs, profile, +# install.sh wrap). Two scripts, one source of truth — DO NOT duplicate +# logic here. +# +# Env / args: +# KEISEI_ROOT install dir (default: $HOME/.local/share/keisei) +# KEISEI_REPO git URL (default: git@github.com:KeiSeiLab/KeiSeiKit-1.0.git) +# KEISEI_REF branch/tag/sha (default: main) +# --profile=NAME passed through to ./bootstrap.sh +# --yes passed through to ./bootstrap.sh +# --ref=REF override KEISEI_REF +# --root=DIR override KEISEI_ROOT + +set -euo pipefail + +KEISEI_ROOT="${KEISEI_ROOT:-$HOME/.local/share/keisei}" +KEISEI_REPO="${KEISEI_REPO:-git@github.com:KeiSeiLab/KeiSeiKit-1.0.git}" +KEISEI_REF="${KEISEI_REF:-main}" + +PASS_THROUGH=() +for arg in "$@"; do + case "$arg" in + --ref=*) KEISEI_REF="${arg#--ref=}" ;; + --root=*) KEISEI_ROOT="${arg#--root=}" ;; + -h|--help) sed -n '1,22p' "$0" | sed 's|^# \{0,1\}||'; exit 0 ;; + *) PASS_THROUGH+=("$arg") ;; + esac +done + +LOG="$HOME/.keisei-install.log" +mkdir -p "$(dirname "$LOG")" +exec > >(tee -a "$LOG") 2>&1 + +say() { printf "\033[1;36m[web-install]\033[0m %s\n" "$*"; } +die() { printf "\033[1;31m[err]\033[0m %s\n" "$*" >&2; exit 1; } + +# ── splash ───────────────────────────────────────────────────────────────── +cat <<'EOF' + + ╔═══════════════════════════════════════════════════════╗ + ║ KeiSeiKit · Exobrain installer ║ + ║ Portable Rust agent substrate for AI coding tools ║ + ╚═══════════════════════════════════════════════════════╝ + +EOF +say "log: $LOG" + +# ── prereq: git (the only thing bootstrap.sh can't self-install) ─────────── +command -v git >/dev/null || die "missing: git (brew install git / apt install git)" + +# ── auth probe for private repo ──────────────────────────────────────────── +case "$KEISEI_REPO" in + git@github.com:*) + say "checking GitHub SSH auth" + if ! ssh -o BatchMode=yes -o StrictHostKeyChecking=accept-new -T git@github.com 2>&1 \ + | grep -qE "successfully authenticated"; then + die "GitHub SSH key not authorised. Add your public key at https://github.com/settings/keys, then re-run." + fi + ;; +esac + +# ── clone or pull (idempotent) ───────────────────────────────────────────── +mkdir -p "$(dirname "$KEISEI_ROOT")" +if [ -d "$KEISEI_ROOT/.git" ]; then + say "pulling $KEISEI_REF in $KEISEI_ROOT" + git -C "$KEISEI_ROOT" fetch --depth=1 origin "$KEISEI_REF" + git -C "$KEISEI_ROOT" reset --hard "origin/$KEISEI_REF" +else + say "cloning $KEISEI_REPO ($KEISEI_REF) → $KEISEI_ROOT" + git clone --depth=1 --branch "$KEISEI_REF" "$KEISEI_REPO" "$KEISEI_ROOT" +fi +git -C "$KEISEI_ROOT" submodule update --init --recursive 2>/dev/null || true + +# ── delegate to kit's own bootstrap.sh ───────────────────────────────────── +[ -x "$KEISEI_ROOT/bootstrap.sh" ] || die "kit's bootstrap.sh not found in $KEISEI_ROOT" +say "delegating to $KEISEI_ROOT/bootstrap.sh ${PASS_THROUGH[*]:-}" +cd "$KEISEI_ROOT" +exec ./bootstrap.sh "${PASS_THROUGH[@]}"