Commit Graph
1674 Commits
Author SHA1 Message Date
Willie fa87ef745f test(integration): end-to-end extras extension transform 2026-05-30 19:23:12 +08:00
Willie c200349540 feat(cmd): skip extension targets in collect; label them in list 2026-05-30 19:23:12 +08:00
Willie 519f7f9412 feat(cmd): apply extension transform during extras sync 2026-05-30 19:23:12 +08:00
Willie aa309d52d7 feat(cmd): resolve extension value and validate transform mode 2026-05-30 19:23:12 +08:00
Willie 1b9d25de7a feat(sync): implement per-file transform with output rename and prune 2026-05-30 19:23:12 +08:00
Willie 425c32d489 refactor(sync): thread extension spec param through SyncExtra 2026-05-30 19:23:12 +08:00
Willie 68607f338f feat(sync): run transform subprocess over a single file 2026-05-30 19:23:12 +08:00
Willie 27e8e55fea feat(sync): add ExtensionSpec and manifest loading 2026-05-30 19:23:12 +08:00
Willie 768dc2e848 feat(config): add extension field to ExtraTargetConfig 2026-05-30 19:23:12 +08:00
Willie e51134af24 feat(git-root): surface scope mismatch in UI and document git_root field
Add Config.GitRootMismatch() as the single source of truth for detecting
when the git repo lives at a different scope than git_root configures, and
reuse it across the CLI guidance, the server status response (scopeMismatch
/mismatchScope/mismatchDir), and a new warning banner on the Git Sync page.

Document git_root in the config structure-view field docs (fieldDocs) and the
GitStatus client type, and add the gitSync.scope.* / gitSync.mismatch.* i18n
keys across all locales to keep dictionary parity.

Cover the behavior with config, server handler, and CLI integration tests:
push/pull honor the root scope (agents files reach the remote, config.yaml
stays untracked), POST /git/root inits+persists the scope and rejects invalid
scopes and project mode, and git status reports scope mismatches.
2026-05-30 19:23:12 +08:00
Willie 54d6706168 feat(ui): switch git_root scope from the Git Sync page 2026-05-30 19:23:12 +08:00
Willie 16c6e8ec8d feat(server): git operations honor git_root scope + POST /git/root to switch scope
- extract shared git.InitScopeRepo/WriteScopeGitignore/EnsureLocalIdentity (UI-free)
- cmd init delegates to the shared helpers (no logic duplication)
- handler_git operations use EffectiveGitRoot; status exposes the scope
- new POST /api/git/root inits a repo at the target scope dir + persists git_root
2026-05-30 19:23:12 +08:00
Willie d6b6b929de feat(ui): validate git_root scope in config editor 2026-05-30 19:23:12 +08:00
Willie 9e371f2dde refactor(git-root): enforce config.yaml exclusion, dedupe scope mapping, warn on scope change
- writeInitGitignore now appends config.yaml to a pre-existing root .gitignore
  if missing (enforces the safety guarantee instead of best-effort)
- single source of truth config.ScopeDir; EffectiveGitRoot/scopeDir/gitRootScopes delegate
- warn when --git-root is passed with --remote on an already-initialized repo
- use 0o644 and check WriteFile errors; add tests for the append + agents scope
2026-05-30 19:23:12 +08:00
Willie 7941ef295a docs: document git_root scope and --git-root flag 2026-05-30 19:23:12 +08:00
Willie e79bde558b test(git-root): cover init --git-root root setup 2026-05-30 19:23:12 +08:00
Willie 757a6c0074 feat(init): scope-aware git init with interactive picker and root .gitignore 2026-05-30 19:23:12 +08:00
Willie d6c21e9638 test(git-root): cover root-scope commit and scope mismatch guidance 2026-05-30 19:23:12 +08:00
Willie 9cad34f3b2 feat(pull): operate on configured git_root scope 2026-05-30 19:23:12 +08:00
Willie e4287f3061 feat(push): operate on configured git_root scope 2026-05-30 19:23:12 +08:00
Willie abeeb93dbe feat(commit): operate on configured git_root scope 2026-05-30 19:23:12 +08:00
Willie d8bf753049 feat(config): add git_root to config JSON schema 2026-05-30 19:23:12 +08:00
Willie a41accc00c feat(cli): add resolveGitRoot scope resolver with mismatch detection 2026-05-30 19:23:12 +08:00
Willie 286070c2a4 feat(config): add git_root scope field and EffectiveGitRoot resolver 2026-05-30 19:23:12 +08:00
김봉섭 62e571fe92 docs(proposals): propose extras in git integration (#171)
skillshare's git integration covers only the skills source today, so
extras (hooks, rules, commands, prompts) sit outside the commit/push/pull
workflow. This proposal asks that extras become a first-class git target.
2026-05-29 16:41:33 +08:00
Willie 244f742a84 docs(readme): add bit3125 to contributors 2026-05-29 01:19:13 +08:00
Willie 046e35a566 fix(devcontainer): forward port 3000 for docs site
The `docs` command starts Docusaurus on :3000 inside the container,
but compose only published 5173 and 19420 to the host. The
`forwardPorts` entry in devcontainer.json only takes effect under
VS Code / the devcontainer CLI; `make devc` uses plain
`docker compose`, which honors only the compose `ports:` mapping.

Publish 3000 so `docs` is reachable from the host browser.
2026-05-29 01:12:28 +08:00
Willie e44896b518 docs(getting-started): restructure for scenario clarity
- index: open with a Mermaid source→targets diagram and describe the
  three kinds of skills that coexist in a source repo (authored,
  vendored, tracked) so readers form a mental model before commands
- first-sync: keep the linear walkthrough as the primary path; add
  Variation sections for restoring on another machine (idempotent
  clone + tracked re-install) and headless setup (CI / devcontainer
  post-create) with the non-interactive flag table
- from-existing-skills: split into single-CLI migration, multi-CLI
  consolidation, and connect-existing-repo paths; surface a backup
  caution before collect since it mutates target directories

Trim filler prose and favor copy-pasteable commands.
2026-05-29 01:12:22 +08:00
Willie d32a15fd94 chore: release v0.19.24 v0.19.24 2026-05-27 17:03:13 +08:00
Willie d6600e744a feat: add UI local commit action 2026-05-27 16:28:50 +08:00
Willie 0becff010e feat: add local commit command 2026-05-27 15:10:00 +08:00
Willie ff8860c9cd fix(ui): preserve update check status after update 2026-05-27 13:56:38 +08:00
Willie e02b2078de chore: release v0.19.23 v0.19.23 2026-05-26 16:01:42 +08:00
Willie 4e532615f6 fix: persist update check status in dashboard 2026-05-26 15:57:36 +08:00
Willie 39011e716c docs: update changelog for v0.19.23 2026-05-26 15:57:23 +08:00
Willie 0e091a5e63 fix: refresh metadata after nested skill updates 2026-05-26 13:37:47 +08:00
Willie 6374134955 chore: release v0.19.22 v0.19.22 2026-05-26 11:09:24 +08:00
Willie 89080cf4f1 refactor(install): typed ambiguity error with counts, save one clone
The mixed-tracked-repo recovery path used a fragile substring match on
the error message and re-cloned the repo via /discover to count skills
and agents. Both problems share one root cause: the counts InferTrackedKind
already computed during the failed first install were thrown away.

- Add install.TrackKindAmbiguousError carrying the discovered Skills /
  Agents counts. InferTrackedKind returns it on the ambiguous branch.
  Error() preserves the legacy message verbatim so CLI output is unchanged.
- Server handleInstall track branch uses errors.As to detect it and emits
  writeCodedError with stable code 'install.track_kind_ambiguous' plus
  skills/agents counts in error_params.
- UI replaces the substring match with an ApiError.code check and reads
  counts straight from err.params, skipping the second /discover clone.
- Add unit tests asserting errors.As, count fidelity, and explicit-kind
  short-circuit (no clone).

Net result: 2 clones instead of 3 on the mixed-track recovery path, and a
stable cross-language contract instead of a brittle English substring.
2026-05-26 11:05:32 +08:00
Willie 209c9d740c fix(ui): support --kind for tracked install of mixed repos (#167)
Installing a mixed git repo (containing both skills and agents) with
'Track' enabled failed with 'tracked install is ambiguous; pass --kind
skill or --kind agent', and the UI gave no way to recover.

- api.install: add optional 'kind' param (backend already supports it)
- InstallForm: detect the ambiguity error, fetch counts via /discover,
  and prompt the user to pick Skills or Agents via a kind-selector
  dialog; re-run install with the chosen kind
- Snapshot all install params (source/name/into/branch/force/skipAudit)
  at error time so a later kind selection cannot drift if the user
  edits the form behind the dialog
- Fall back to the original ambiguity error if /discover fails, so the
  user is not left with only a confusing secondary error
- Render the kind selector in both collapsible and non-collapsible
  return branches so the fix works for any InstallForm caller
- preventClose while installing so an in-flight kind selection is not
  cancelled by Escape / backdrop click
- Hoist KindOption out of the render body to keep its component
  identity stable across parent re-renders (no more autoFocus refire)

UI redesign of the kind selector:
- Replace ConfirmDialog wrapper with DialogShell + stacked card-style
  kind buttons (icon + label + count + chevron)
- Title row gains an X close affordance; remove the redundant bottom
  Cancel/divider to match other modals

i18n: drop legacy skillsButton/agentsButton/cancelText keys; add
skillsLabel/agentsLabel/itemCount across all 11 locales with fully
native phrasing (no mixed English in non-English locales).
2026-05-26 10:47:09 +08:00
Willie a565b6872b chore: release v0.19.21 v0.19.21 2026-05-25 00:37:09 +08:00
Willie 012a4ba97e fix(ui): resolve stuck update checks 2026-05-25 00:33:26 +08:00
Willie 6fbc7cd8bd chore: release v0.19.20 v0.19.20 2026-05-24 01:27:02 +08:00
Willie a2f958d288 feat(ui): background mode, in-place upgrade, and PWA support
Three user-visible additions to the web dashboard, plus the CLI surface
needed to drive them.

* `skillshare ui start` / `skillshare ui stop` — run the dashboard as a
  managed background process. Re-running start reuses the existing
  healthy process; stop uses the remembered host/port. Foreground
  `skillshare ui` keeps working unchanged. Process tracking lives in
  ui_process_{unix,windows,other}.go via a PID + current-state file.
* `--app` — opens the dashboard in a Chromium app-mode window (Chrome,
  Edge, Brave) on macOS, Windows, and Linux for a separate Dock/taskbar
  entry without browser chrome.
* In-place upgrade from the browser — the Update dialog and the Doctor
  page's Version card now expose an Update now button. Backed by two
  new endpoints (POST /api/upgrade, POST /api/restart in
  handler_restart_upgrade.go); the browser polls GET /api/health and
  reloads once the new server is ready. Dev builds short-circuit with
  `devMode: true` and a simulated restart so the flow can be exercised
  without rebuilding the binary.
* Progressive Web App — site.webmanifest, app icons (192/512), and a
  minimal service worker registered from main.tsx. Supporting browsers
  can install the dashboard as a standalone desktop app.
* Doctor Version card redesign — state-coloured icon (blue when an
  update is available, green when up to date), explicit
  `current → latest` delta, Update button only when there is something
  to upgrade.
* i18n — translate "DEV mode" in zh-TW / zh-CN / ko (previously left
  as raw English).

Adds CHANGELOG.md and website changelog entries for v0.19.20 and
refreshes website/docs/reference/commands/ui.md to document the new
modes, --app flag, new REST endpoints, and the in-place upgrade flow.
2026-05-24 01:21:06 +08:00
Willie c60bfd3c08 chore: release v0.19.19 v0.19.19 2026-05-23 01:18:38 +08:00
Willie 6f0e4b46df docs(readme): add @xarthurx and @m0cun to contributors 2026-05-22 15:07:32 +08:00
Willie 9163d3b559 chore: release v0.19.18 v0.19.18 2026-05-22 14:48:59 +08:00
Willie 1307873612 fix(install): normalize SSH subgroup repo names 2026-05-22 14:04:46 +08:00
WillieandClaude a61a0e3bea fix(install): include root SKILL.md in tracked repo discovery
After Phase A (210605ea) fixed metadata + status display for tracked
repos with a root-level SKILL.md, three output gaps remained:

- 'Found 0 skill(s)' on install (should be 1 — root SKILL.md counts)
- 'tracked_repos[].skill_count' was 0 (same root-case)
- 'Run sync' suggestion appeared even when no skill was discovered

Root cause: install/update used discoverSkills(destPath, false) which
walks the tracked repo's own root, treating the root SKILL.md at
relPath='.' as ignored. But 'skillshare sync' walks the source
directory; the same SKILL.md inside _<name>/ has relPath='_<name>'
(not '.') and is discovered as a normal skill. The two walkers used
the same helper with different includeRoot settings and produced
inconsistent counts.

Changes:

- installTrackedRepoImpl and updateTrackedRepo: switch to
  discoverSkills(repoPath, true) so SkillCount matches sync's view.

- buildTrackedRepoJSON: when counting skills per repo, accept both
  RelPath='<repo>/...' (nested) and RelPath='<repo>' (root-only).

- handleTrackedRepoInstall: suppress the 'Run sync' next-step when
  the repo had no skills/agents discovered.

Closes #163

Co-authored-by: Claude <noreply@anthropic.com>
2026-05-22 11:29:01 +08:00
WillieandClaude 210605ea4e fix(install): persist metadata for tracked repos with root-level SKILL.md
When --track installed a repo whose SKILL.md sits at the repository root
(non-spec layout), the install reported success but:

- .metadata.json gained no entry (cross-machine recovery via metadata broken)
- status --json tracked_repos did not list the repo

Two coupled bugs caused this:

1. cmdInstall gated ReconcileGlobalSkills on len(InstalledSkills) > 0.
   Tracked repos with no discoverable nested skills produced an empty
   InstalledSkills slice, so reconcile never ran and never detected the
   _<name>/.git directory to write a tracked entry.

2. extractTrackedRepos derived repo names from discovered skills, so
   repos with zero discoverable skills were silently dropped from status
   and list output.

Fix both by:

- Making the post-install reconcile unconditional on success. Reconcile is
  idempotent and cheap; gating it on InstalledSkills > 0 created a path
  where successful installs left metadata stale.

- Switching extractTrackedRepos to install.GetTrackedRepos (a directory
  walk for _-prefixed git repos), the same source-of-truth used by check
  and update. Shared across status, status_project, list, and list_project.

Closes #163

Co-authored-by: Claude <noreply@anthropic.com>
2026-05-22 10:57:55 +08:00
Willie d364edd698 chore: release v0.19.17 v0.19.17 2026-05-22 01:34:26 +08:00