Moves all Mosaic framework runtime files from the separate bootstrap repo into the monorepo as canonical source. The @mosaic/mosaic npm package now ships the complete framework — bin scripts, runtime configs, tools, and templates — enabling standalone installation via npm install. Structure: packages/mosaic/framework/ ├── bin/ 28 CLI scripts (mosaic, mosaic-doctor, mosaic-sync-skills, etc.) ├── runtime/ Runtime adapters (claude, codex, opencode, pi, mcp) ├── tools/ Shell tooling (git, prdy, orchestrator, quality, etc.) ├── templates/ Agent and repo templates ├── defaults/ Default identity files (AGENTS.md, STANDARDS.md, SOUL.md, etc.) ├── install.sh Legacy bash installer └── remote-install.sh One-liner remote installer Key files with Pi support and recent fixes: - bin/mosaic: launch_pi() with skills-local loop - bin/mosaic-doctor: --fix auto-wiring for all 4 harnesses - bin/mosaic-sync-skills: Pi as 4th link target, symlink-aware find - bin/mosaic-link-runtime-assets: Pi settings.json patching - bin/mosaic-migrate-local-skills: Pi skill roots, symlink find - runtime/pi/RUNTIME.md + mosaic-extension.ts Package ships 251 framework files in the npm tarball (278KB compressed).
118 lines
3.1 KiB
Bash
Executable File
118 lines
3.1 KiB
Bash
Executable File
#!/bin/bash
|
|
# milestone-create.sh - Create milestones on Gitea or GitHub
|
|
# Usage: milestone-create.sh -t "Title" [-d "Description"] [--due "YYYY-MM-DD"]
|
|
|
|
set -e
|
|
|
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
source "$SCRIPT_DIR/detect-platform.sh"
|
|
|
|
# Default values
|
|
TITLE=""
|
|
DESCRIPTION=""
|
|
DUE_DATE=""
|
|
LIST_ONLY=false
|
|
|
|
usage() {
|
|
cat <<EOF
|
|
Usage: $(basename "$0") [OPTIONS]
|
|
|
|
Create or list milestones on the current repository (Gitea or GitHub).
|
|
|
|
Versioning Convention:
|
|
- Features get dedicated milestones
|
|
- Pre-MVP milestones MUST use 0.0.x and MUST start at 0.0.1
|
|
- 0.1.0 is reserved for MVP release
|
|
- After MVP, continue semantic progression (0.1.x, 0.2.x, ...)
|
|
|
|
Options:
|
|
-t, --title TITLE Milestone title/version (e.g., "0.0.1")
|
|
-d, --desc DESCRIPTION Milestone description
|
|
--due DATE Due date (YYYY-MM-DD format)
|
|
--list List existing milestones
|
|
-h, --help Show this help message
|
|
|
|
Examples:
|
|
$(basename "$0") --list
|
|
$(basename "$0") -t "0.0.1" -d "Pre-MVP Foundation Sprint"
|
|
$(basename "$0") -t "0.1.0" -d "MVP Release" --due "2025-03-01"
|
|
EOF
|
|
exit 1
|
|
}
|
|
|
|
# Parse arguments
|
|
while [[ $# -gt 0 ]]; do
|
|
case $1 in
|
|
-t|--title)
|
|
TITLE="$2"
|
|
shift 2
|
|
;;
|
|
-d|--desc)
|
|
DESCRIPTION="$2"
|
|
shift 2
|
|
;;
|
|
--due)
|
|
DUE_DATE="$2"
|
|
shift 2
|
|
;;
|
|
--list)
|
|
LIST_ONLY=true
|
|
shift
|
|
;;
|
|
-h|--help)
|
|
usage
|
|
;;
|
|
*)
|
|
echo "Unknown option: $1" >&2
|
|
usage
|
|
;;
|
|
esac
|
|
done
|
|
|
|
PLATFORM=$(detect_platform)
|
|
|
|
if [[ "$LIST_ONLY" == true ]]; then
|
|
case "$PLATFORM" in
|
|
github)
|
|
gh api repos/:owner/:repo/milestones --jq '.[] | "\(.number)\t\(.title)\t\(.state)\t\(.open_issues)/\(.closed_issues) issues"'
|
|
;;
|
|
gitea)
|
|
tea milestones list
|
|
;;
|
|
*)
|
|
echo "Error: Could not detect git platform" >&2
|
|
exit 1
|
|
;;
|
|
esac
|
|
exit 0
|
|
fi
|
|
|
|
if [[ -z "$TITLE" ]]; then
|
|
echo "Error: Title is required (-t) for creating milestones" >&2
|
|
usage
|
|
fi
|
|
|
|
case "$PLATFORM" in
|
|
github)
|
|
# GitHub uses the API for milestone creation
|
|
JSON_PAYLOAD="{\"title\":\"$TITLE\""
|
|
[[ -n "$DESCRIPTION" ]] && JSON_PAYLOAD="$JSON_PAYLOAD,\"description\":\"$DESCRIPTION\""
|
|
[[ -n "$DUE_DATE" ]] && JSON_PAYLOAD="$JSON_PAYLOAD,\"due_on\":\"${DUE_DATE}T00:00:00Z\""
|
|
JSON_PAYLOAD="$JSON_PAYLOAD}"
|
|
|
|
gh api repos/:owner/:repo/milestones --method POST --input - <<< "$JSON_PAYLOAD"
|
|
echo "Milestone '$TITLE' created successfully"
|
|
;;
|
|
gitea)
|
|
CMD="tea milestones create --title \"$TITLE\""
|
|
[[ -n "$DESCRIPTION" ]] && CMD="$CMD --description \"$DESCRIPTION\""
|
|
[[ -n "$DUE_DATE" ]] && CMD="$CMD --deadline \"$DUE_DATE\""
|
|
eval "$CMD"
|
|
echo "Milestone '$TITLE' created successfully"
|
|
;;
|
|
*)
|
|
echo "Error: Could not detect git platform" >&2
|
|
exit 1
|
|
;;
|
|
esac
|