43 Commits
Author SHA1 Message Date
3217d44881 fix(reconcile): keep tracked repo declarations this machine has not cloned (#880)
* test(install): reproduce loss of pulled tracked records

Exercise the two-machine push and pull sequence and reconciliation states so
missing tracked clones cannot silently erase shared install intent.

* fix(reconcile): preserve tracked records missing local clones

Pull transfers tracked repository metadata but not ignored clones. Keep the
missing records during global reconciliation so another install and push cannot
erase shared intent or accepted audit findings on every machine.

* test(reconcile): isolate tracked record fixtures

Use the shared sandbox fixture for both reconciliation tests so their home
and configuration paths remain isolated from the invoking environment.

* fix(reconcile): retain all sourced tracked declarations

Legacy tracked members and unfollowed source links can hide declarations
from the local walk. Preserve sourced tracked records regardless of their
path so unrelated installs cannot erase them or their audit acceptances.

Document restoring a missing checkout before uninstalling it and cover
migration, link collisions, aliases, and explicit removal.

* test(reconcile): drop fixtures existing tests already pin

The tracked-record unit test also seeded a missing plain record and a
live plain record. TestReconcileGlobalSkills_PrunesStaleEntries already
pins both outcomes: a sourced plain record whose folder is gone is
pruned, and one on disk survives. The tracked record with no source
still catches a fix that keeps everything or skips the prune.

The two-machine test passed HOME and SKILLSHARE_CONFIG to RunCLIEnv,
which already sets both from the sandbox for each child process.
Separate homes, XDG paths, client overrides and git config remain.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(reconcile): retain tracked entry for unavailable link

Expect sourced tracked declarations to survive reconciliation with either
source-link policy, so the test matches the cross-machine retention contract.

* fix(config): prune legacy tracked members

Retain only sourced tracked repository declarations during reconciliation.
Migrated member records are not restorable as repositories and retaining them
would leave permanent misleading install requests and audit acceptances.

* fix(reconcile): preserve tracked intent across followed links

A source link can exist before a tracked repository declaration is pulled. Preserve that declaration when the linked folder is not a checkout so later reconciliation does not discard its record and audit acceptances.

* test(reconcile): cover grouped followed declarations

A followed group can contain the path of a pulled legacy repository declaration, which must retain its tracked intent while its key migrates.

* fix(test): scope collision fixture runner correctly

Keep the isolated CLI runner in the collision subtest that uses it so the integration test package can compile.

* docs(manifest): clarify tracked checkout recovery

A retained declaration cannot restore a checkout while another folder or source link occupies its destination, and restoration requires a reachable source. State those prerequisites in each manifest translation.

* fix(config): prune members under recorded repositories

A migrated underscore-named member can otherwise survive a missing checkout as a repository declaration. Check recorded ancestor paths while preserving ambiguous grouped declarations and unrelated aliases.

* docs(manifest): restore fresh-clone project guidance

Explain that project declarations without local install records remain available so teammates can install them after cloning.

* refactor(reconcile): drop the tracked-intent walker policy

Restore baseline normalization for present paths while retaining absent
repository declarations through the shared metadata predicate. Isolate the
reconcile fixtures without building a CLI and share native-client overrides
without changing the original two-machine record and audit regression.

Validation: gofmt, git diff --check and context-router check only.
Runtime, builds and tests were not executed under the source-only gate.

* fix: forget linked checkout records and declarations without checkouts

Extend the metadata and uninstall owners to remove a declaration without
reading or moving its occupant, contacting its source, or changing trash
and gitignore. A failed metadata save makes every metadata-only result fail.

Clean up global unlink records in CLI and API, preserve existing-path name
precedence, report record-only results truthfully, and list declarations in
the dashboard API with noCheckout. Keep project removal behavior unchanged.
Remove the obsolete grouped-link walker-policy assertion while preserving
grouped absent declarations and the original record/audit A/B regression.

Validation: source-only five-pass review, gofmt, git diff --check and the
context-router check. No runtime, builds, tests or frontend tooling ran.
Stop at commit 15 for the mandatory Luna checkpoint before UI and docs work.

* fix(server): reload metadata before removing declarations

Preserve CLI records and audit acceptances written while the dashboard is open. Resolve new declarations from disk and refuse stale-cache saves after a reload failure, retaining unlink success when its link already moved.

* feat(dashboard): remove a tracked repository record without a checkout

Show declaration-only rows without checkout actions or status promises. Reuse Uninstall with record-specific confirmation and feedback, keep real-checkout force handling, and refresh the missing-entry list after repository removal or unlink.

* docs: explain kept declarations and how to remove them

Document direct global declaration removal and optional restore in English and all four translations, including occupied paths and normalization after reconcile. Keep built-in guidance accurate and use the existing API removal result for dashboard success feedback after concurrent CLI changes.

* fix(dashboard): confirm restored checkouts after forceable refusals

A tracked declaration can be restored through the CLI while its dashboard
row still says there is no checkout. Treat a forceable uninstall refusal
as evidence of the current checkout and promote the existing confirmation
to its dirty or unreadable-status warning before allowing explicit force.

Author stale-row regressions for both forceable codes before the source
repair, and retain nonforceable failure and actual-result success feedback.
Validation: five serial source review passes, git diff --check, and the
context-router check. Tests, builds, runtime and frontend tooling were not
run under the source-only gate.

* test(server): persist overview declarations before routed request

The overview fixture added declarations only to the in-memory skills store,
which the real request's config reload replaced with on-disk metadata. The
hosted unit, offline, and Nix jobs consequently returned no tracked rows.

Save the complete fixture through MetadataStore before serving the request
and fail setup on a save error. Keep the middleware, assertions, and
production behavior unchanged.

* fix(server): prefer exact declarations before checkout shorthand

Removing a missing _team declaration from the dashboard could resolve the
different org/_team checkout by basename and trash it instead.

Reload metadata before declaration lookup, give exact declarations priority,
and preserve checkout resolution before non-exact declaration fallback.
Add routed absent/occupied regressions and checkout precedence guards, and
persist existing checkout fixtures so the metadata reload keeps their state.

Validation: gofmt, git diff --check, and context-router check passed.
Tests were authored but not run under the source-only fleet restriction.

* fix: preserve removal intent and report partial failures

Bind dashboard record-only removal to its canonical declaration and refuse
restored checkouts before checkout resolution or force. Refresh the row and
require another confirmation before moving a restored checkout to trash.

Keep unresolved uninstall inputs and their reasons in JSON failed results,
including all-invalid requests, partial successes and dry runs. Report unlink
metadata cleanup failures as partial results, refresh completed unlinks and
show localized warnings. Keep CLI and dashboard guidance aligned.

Regression tests were authored before source changes and remain unrun under
the source-only task restriction. Static formatting, diff and router checks
passed; no build, product runtime, frontend tooling or test suite was run.

* fix(unlink): log partial metadata cleanup failures

Write the unlink result after global metadata cleanup so load and save
failures retain their diagnostic and report partial success. Preserve the
successful link removal, warning, target and exit policy, and the existing
link, project unlink and native removal failure behavior.

Add the corrupt-metadata regression before the fix; leave it unrun under
the source-only authorization. Formatting, diff and context-router checks
pass; runtime verification remains with the coordinator.

* fix(unlink): forget records below the removed link name

Reconcile can normalize a followed link's record to untracked, and linked
collections can retain nested repository declarations. Clean the removed
namespace through the existing metadata path owner in both unlink callers,
including audit acceptances, while keeping declaration uninstall strict.

Author CLI and route regressions before the source fix for normalized and
nested records, sibling preservation, and subsequent bare install. Tests
remain unrun under the source-only task restriction; static checks only.

* fix(uninstall): refuse a restored checkout at execution

A declaration selected while absent can become a checkout before removal
runs. Recheck the resolved source-relative name in the shared metadata-only
execution owner and refuse before touching metadata, regardless of force.

Reuse the existing dashboard conflict response and refresh/reselection flow
for this refusal, preserving the earlier record-only intent guard. CLI
results already carry shared execution failures through text and JSON.

Author restoration, force, absent/occupied control and client boundary
regressions before production edits. Correct the unlink fixture name and
response-key assertion found in serial static review. All tests remain
unrun under the source-only restriction; formatting/diff/router checks pass.

* refactor(server): consolidate repository uninstall result handling

Resolve a declaration or checkout to one item and canonical name before
using the existing uninstall, conflict, log and success response tail.
Keep metadata-only removal unforced, preserve its error and cache recovery
behavior, and report movedToTrash from the selected item.

Preserve exact declaration precedence, record-only checkout refusals,
ordinary checkout errors and project behavior without changing tests.
Five serial source review passes, gofmt, diff checks and the context-router
check completed. Tests and builds remain unrun under the source-only brief.

* fix(unlink): preserve independent records and trash undo metadata

Limit unlink's legacy group matching to members so a retained declaration
such as team/_repo survives unlinking _team. Share snapshot and removal
matching while keeping generic uninstall's legacy contract unchanged.

Save the exact removed records, audit acceptances and target overrides
through uninstall's existing trash sidecar owner before pruning metadata.
Keep metadata on sidecar failure and preserve completed-unlink warnings,
fresh reloads, cache refresh and project-mode behavior.

Author owner, CLI and API regressions for namespace collisions, undo,
partial failures and project/empty controls. Source-only verification:
gofmt, diff check and context-router check passed; runtime tests, builds,
frontend checks and final make check remain unrun for root-owned gates.

* fix(install): preserve independent tracked declarations

Limit declaration-only cleanup to the precise namespace and legacy members already used by unlink. Keep independently installed prefixed repositories, their audit acceptances, and overrides when forgetting a missing checkout.

* fix(cli): explain missing tracked repository recovery by mode

Offer global record removal when restoring an unreachable source is unwanted. Keep project recovery scoped to install -p, share the hint with doctor, and align update documentation in every existing locale.

* refactor(uninstall): share declaration and unlink operations

Keep declaration resolution and unlink metadata ordering in shared owners so CLI and API preserve the same scope and recovery behavior. Consolidate domain regressions while retaining caller translation coverage.

Distinguish record-only removals in API and CLI operation logs and CLI JSON, including mixed batches and dry runs. Document outcome fields, warning semantics, and current API error codes across existing locales.

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Willie <egg358358@gmail.com>
2026-11-14 13:11:27 +08:00
Willie 51089307f8 docs: prepare README and troubleshooting for 0.30.7 (#888)
The 0.30.7 release adds `audit --respect-accepted`, so the README
"Latest" callouts in every language now point to it, and the release's
external reporter joins the contributors list.

An install whose audit cannot run, for example because audit-rules.yaml
does not parse, now fails with "audit scan failed", and --force does not
override it. The troubleshooting page only suggested --force for audit
errors, so it gains an entry for this error in English and the four
translated docs. The zh-Hant audit page also had the new
--respect-accepted flag row left in English.
2026-11-14 00:20:59 +08:00
Willie bb514c9432 fix(git): skip gitignored tracked repos in the root-scope nested repo check (#821)
With git_root: root, commit and push aborted on every tracked skill repo
because NestedRepos flagged any directory with its own .git. Tracked repos
are listed in the managed .gitignore block, so git add -A never stages
them, and the suggested remedy (renaming .git to .git.disabled) breaks
skillshare update for those repos.

NestedRepos now asks git check-ignore about each nested repo and leaves
out the ones git ignores and does not track. A repo already committed as
a gitlink is still reported, since staging would update it. Paths are
checked one at a time because git refuses a whole batch when one path
lies inside a gitlink, and any git error keeps the warning.

Closes #820
2026-11-10 01:00:03 +08:00
Willie 53a3207a17 fix(update): keep an agent's source when updating it (#778)
* fix(update): keep an agent's source when updating it

After the first `update agents`, an agent's recorded source became
`/agents/<name>.md` with type `unknown-subdir` and no repo URL, so
`check agents` stopped looking upstream and later changes never arrived
(#777).

The batch path rebuilt the repository source from the clone URL, subdir
and branch only, leaving Raw and Type empty, and the metadata written
back was built from that empty Raw. The fallback reinstall and the
dashboard update kept the agent's full source as Raw while clearing the
subdir, so the written source repeated the agent path.

AgentRepoSource now rebuilds the repository source once, by cutting the
agent path off the recorded source, and all three paths use it, so the
source written back is the one install recorded.

Agents whose metadata was already rewritten have no repository left in
it and need to be installed again.

* fix(check): compare each agent at its own branch and report unchecked agents

Agent update checks gave wrong answers in several cases next to #777:

- Agents from one repository were compared with the first agent's
  version, so an older agent sharing a repo with a current one never
  showed its update.
- The installed branch was never sent to the remote, so an agent pinned
  to a non-default branch was compared with the default branch head.
- A tracked agent repo records its full commit while the remote hash is
  abbreviated, so a fresh clone always read as update_available; its
  checked-out branch was also ignored.
- `update agents` printed "All agents are up to date" and exited 0 when
  agents could not be checked at all: an unreachable remote, unreadable
  metadata, or a source erased by the #777 bug.

Each agent is now compared with its own version at its own branch, and
an agent whose source the old bug erased reports an error asking for a
reinstall, since its metadata no longer names a repository. Update lists
the agents it could not check and exits non-zero, counting them apart
from agents that failed to update. The docs describe the error status
and the reinstall fix.

* fix(update): repair dashboard-doubled agent sources and share the update flow

Review of the previous commits found gaps in recovering agents that
earlier updates broke, and in how the two update handlers report them:

- A dashboard update before the #777 fix appended the agent path to its
  source a second time. Those agents keep their repo URL, so check offers
  an update, but discovery then failed on the doubled path. Every copy of
  the path is now cut, and the update writes the source back correctly.
- On the dashboard, an agent whose source the CLI bug erased failed with
  "invalid source: source cannot be empty". AgentRepoSource now returns
  the same reinstall error check shows, and both use one detector.
- When every tracked agent was such an erased agent, no remote was asked,
  so the "Checking agents" spinner was never stopped and drew over the
  error rows. It is now stopped once the check returns.
- The global and project handlers repeated the check-and-update flow,
  and the project copy had already drifted (no dry-run log entry, spinner
  in --json). Both now run one shared flow.

Tests cover the erased agent next to an updatable one in global, --json,
--dry-run and project mode, and the doubled and erased sources in
AgentRepoSource.
2026-11-04 22:15:55 +08:00
Rusty Shackleford da3383ed5f fix(plugins): separate shared intent from local installation state (#660)
* fix(plugins): separate shared intent from machine-local receipts

Shared configs currently carry native paths, reviewed snapshots and pending
failures, so one host can publish local progress over another host's target
selection. Persist versioned declarations separately from local applied and
pending receipts, and reconcile reviewed installs, imports and cleanup against
this machine's native inventory without rewriting intent during sync/update.

Keep snapshot names and adapter safeguards, move the operation lock locally,
validate legacy adoption with local evidence, and invalidate approval on local
state or native-context changes. Preserve source recipes after native adoption,
require local import for absent native-only targets, and document the shared
writer upgrade boundary in schemas and translated references.

Cover two-host behavior, generated legacy fixtures, failure/recovery, stale
intent, cleanup, npm recipes and the existing CLI/API/UI consumers with focused
resource-capped tests. Fixes #651.

* fix(plugins): preserve intent and ownership across host transitions

Repeat-add must retain shared target selection, and update previews must resolve
the requested ref before reviewing fresh or replacement installs. Keep disabled
targets on the uninstall path and reject refs unsupported by native-only/npm
intent before they can produce invalid shared declarations.

Block changed-context add/import before Pi registration preparation so a new
account cannot overwrite the old receipt. Preserve unresolved legacy bindings
as passive private proof candidates before rewriting shared YAML, retaining
original intent/store for later verified adoption and cleanup. Never compose
these hints as executable state, and persist their explicit resolution.

Cover the five review classes, native/private failure boundaries, requested-ref
retry, and original-context hint proofs with isolated focused regressions.
Keep local format v1 and baseline account validation unchanged. Refs #651.

* fix(plugins): allow receipt-only orphan cleanup to complete

An installation already removed on this host can retain a local receipt when
another host removes or replaces shared intent. Sync correctly plans forget,
but native command verification rejects that metadata-only action and blocks
all targets before the receipt can be cleared.

Exclude forget from native command verification while retaining host inventory
checks and OMP scoped cleanup preparation. The existing completion path then
persists receipt deletion, including pending work and passive legacy hints.

Cover the cross-host disable/re-enable/remove walk, five native adapters,
failed work with a legacy hint, and absent source replacement alongside a
healthy target. Assert Apply completion, unchanged shared bytes/mtime, and a
quiet second sync. Refs #651.

* fix(plugin): reconcile ref intent across inventory consumers

Validate explicit ref changes before disabled targets can save them and reuse
one reviewed discovery throughout a preview. Surface shared ref changes as local
reconciliation work while preserving the applied native identity and receipts.

Reuse scoped legacy proofs for Pi extension ownership and make full inventory
the dashboard's authoritative package/host pair. Cover invalid and replacement
refs, read-only ownership, and shared-state properties without new persisted
state or dependencies.

* test(plugin): repair and consolidate host-state fixtures

Create source intent and a pending imported Claude update through supported
operations so direct and batch updates exercise the intended fixture. Keep the
marketplace-loss case locally owned before testing its skipped reinstall.

Consolidate cross-host repeat-add and requested-ref replacement/orphan retries
at their existing owners, retaining failure recovery and shared-byte checks.
Trim duplicate HTTP and translated-text assertions from consumer tests.

* fix(plugin): reconcile legacy snapshot reads and native imports

Resolve legacy snapshot ownership through existing scoped proofs before listing,
reading or discovering cached source files. Keep adoption read-only and limit
proof work to the requested package and targets; current receipts need no CLI.

Only preserve reviewed source metadata on reimport when intent remains source
managed. Native-only intent must not resurrect an older Git source after a
same-ID local import. Retain identity mismatch and reviewed-source safeguards.

Remove the unused source-folding helper left by the old shared runtime writer.

* Preserve reviewed package versions locally

* Fix reviewed package version lifecycle

* fix(plugin): report missing local imports in doctor

Show the local-import instruction instead of claiming a skipped imported
plugin is healthy. Preserve the missing-CLI warning and shared config bytes.

Keep fixture native settings inside scratch XDG directories and serialize
the fake CLI calls used by concurrent inventories. Update assertions to
separate shared declarations from local versions and native IDs, and align
the raw-write audit with private plugin state and operation locks.

* test(plugin): use declarations for doctor source fixture

The missing-CLI case has no native ID, so encode it with the version 2
declaration schema. Keep the native-only import case in legacy syntax.

* fix(plugin): install shared sources from reviewed snapshots

When a source target is already declared, first sync must install its
reviewed local snapshot even if the native client has a package from the
same marketplace. Keep explicit add adoption and native-only import intact.

Extend the existing two-host adoption check to cover an independent native
installation on the second host and verify a quiet subsequent sync.

* fix(plugin): preserve reviewed retries and native collision boundaries

Retry a pending source update through the existing reviewed update path,
so a rolled-back native failure cannot clear progress at the old snapshot.
Record default-source versions for add, sync, and update while retaining
the recipe fingerprint and generic-version checks for target overrides.

Keep explicit native adoption, but block shared Claude sources when an
independent same-name native plugin could shadow their hooks. Extract the
existing adoption decision so the preview function becomes smaller.

* test(plugin): respect OMP update safety in version control

Check generic and target versions during review, then confirm the existing
OMP upgrade guard preserves the installed and default-source versions.

* fix(plugin): declare first local native imports explicitly

A first local import into a shared source target now changes that target
to native-only intent while preserving its sync selection. Verified source
reimports retain their reviewed source and the preview discloses conversion.

Cover the explicit import, local sync, and other-host cleanup flow, and
remove the unconsumed internal observation assertion from the OMP test.

* docs(plugin): explain first local import intent changes

Describe the shared native-only target conversion and its effect on other
machines, while distinguishing verified source reimports.

* fix(plugin): verify checked sources before native reinstalls

A checked update that becomes an install after native removal must still
match the source digest the user approved. Reject moved or unchecked
sources before native work, and allow a stable approved reinstall.

Clear completed reinstalls from dashboard update availability while keeping
failed targets available for retry. Cover both native presence states in
the existing checked-update tests and the dashboard outcome rule.

* fix(plugin): guard replacement before cleanup

* fix(plugin): refresh discovery for each manager action

A later Add action must review the current source even when the manager
previously observed that source. Keep discovery sharing across one action
while ending its cache before the next wizard invocation.

Exercise a fresh source version after an earlier Add preview without TTY
input or native writes, using an unavailable client to stop at review.

* test(plugin): cover desired checks and final update outcomes

Consolidate checked batch approval and dashboard completion tests while
retaining removed-native, digest, version and approval controls. Reproduce
stale shared recipes and failed or unfinished replacement installs.

* test(plugin): make stale source discovery observable

Remove the old repository before native-only and npm desired checks so
those existing cases cannot pass by reading the applied source.

* fix(plugin): check desired source and final outcome

* test(plugin): bind checked updates to the observed recipe

Reproduce a shared candidate change with equal version, commit and digest,
and preserve a freshly checked replacement whose native ID differs. Use
actual check observations in approval and native update controls, reject
missing source identity, and verify the UI carries the observation through.

* fix(plugin): bind checked update to source recipe

* fix(ui): classify npm recipes as Pi packages

* fix(plugin): retain legacy removal intent during migration

Omit pending removals from shared declarations while retaining original local ownership proof so sync retries cleanup.

Verification: focused regression passed in an isolated Linux Codex container, not the devcontainer (GOMAXPROCS=4, -p=4).

* fix(plugin): keep imports local to an existing shared recipe

Adopt a native installation into its local receipt without converting the shared source target or removing other machines installations.

Verification: focused import regressions passed in an isolated Linux Codex container, not the devcontainer (GOMAXPROCS=4, -p=4).

* fix(plugin): capture legacy evidence on first read

Persist passive hints before another machine writes v2 and save verified adoption on reads. Apply reuses preview receipts instead of querying every legacy binding again. Document the per-machine pre-migration read.

Verification: migration regressions passed in isolated Linux Codex container runs, not the devcontainer (GOMAXPROCS=4, -p=4).

* fix(plugin): target named declarations in interactive imports

Offer unresolved package names in dashboard and TUI imports and pass the selected name in single and batch requests. Drop display-only rendered assertions.

Verification: 47 UI tests passed with at most four workers in an isolated Linux Codex container, not the devcontainer.

* fix(plugin): localize shared intent plan guidance

Add message keys for local imports, account changes, cleanup and native collisions across all dashboard locales. Localized guidance contains no CLI flags.

Verification: failing localization regression now passes in an isolated Linux Codex container, not the devcontainer (GOMAXPROCS=4, -p=4).

* refactor(plugin): reuse preview inventory and guard apply boundaries

Capture hints on first load without persisting in-memory adoption during preview, keeping approval revisions stable. Apply reuses preview inventory. Reuse accountEnv and guard applyChange plus native write boundaries without inspecting argv.

Verification: migration, receipt, account and sync regressions passed in an isolated Linux Codex container, not the devcontainer (GOMAXPROCS=4, -p=4).

* test(plugin): organize host state coverage around lifecycle scenarios

Group migration, ref drift, account context and cleanup tests behind shared host fixtures and public Preview/Apply assertions. Cover Codex, Cursor, Antigravity and project scopes; add second-machine doctor coverage and the two-machine runbook. Consolidate package-version tests and remove the unused private-record fixture.

Verification: focused plugin regressions passed in an isolated Linux Codex container, not the devcontainer (GOMAXPROCS=4, -p=4).

* docs(plugin): explain local imports and per-machine migration

Document local receipts, per-machine review and commit pinning, config-path state identity and the required legacy read on every machine. Align sharing, doctor, troubleshooting, file-layout and four translated plugin references; restore schema editing guidance.

Verification: context-router check passed. Runtime verification uses an isolated Linux Codex container, not the devcontainer.

* refactor(plugin): separate unrelated review scope

Move project OMP configuration, plugin list ordering, and npm Pi classification to independent local branches based on upstream/main. Keep the shared intent change focused and cover named import selection in the pure flow helper.

The three local branches have passing builds in a Linux Codex container, not the devcontainer, with isolated test homes and capped parallelism.

* perf(plugin): avoid recapturing v2 state on reads

Only compare and persist passive migration hints when legacy bindings exist. Native v2 reads need no state serialization for migration.

Verification: pending removal and first-read/import regressions passed in a Linux Codex container, not the devcontainer, with isolated HOME/XDG/TMPDIR and GOMAXPROCS=4 GOFLAGS=-p=4.

* docs(plugin): clarify native marketplace repair after import

A local import receipt is not a reviewed reinstall source. Correct the remaining troubleshooting instruction and its four translations to require native-client repair, and align the nearby code comment.

Validation: checked against prepareChange, context-router check and git diff --check passed. Verification for this review ran in a Linux Codex container, not the devcontainer.

* fix(plugins): preserve local ownership across shared intent changes

Retain completed legacy migration markers so unchanged v1 YAML cannot
uninstall a later manual reinstall. Serialize read-side hint persistence
with native operations and keep local imports when shared recipes change.
Require explicit dashboard import names and validate recipe identities.

Correct schema descriptions, messages, CLI ref status, translated migration
guidance and runbooks. Add failing-first Preview/Apply regressions and a
real two-ssenv CLI lifecycle script.

* fix(plugins): preserve migration history and show retained import guidance

Mark existing legacy hints and receipts as captured before cleanup so state
from the previous serializer cannot re-adopt a later manual installation.
Keep recipe-change guidance in unchanged sync outcomes and visible dashboard
rows, and resolve nested OpenCode entries through their package manifest.

Cover public migration, ref, account, import and message contracts across
adapters. Correct the real two-host Cursor assertions, explicit dashboard
selection flow, and remaining localized guidance.

* fix(plugins): retain explicit OpenCode entry during import matching

Standalone OpenCode packages can rely on a reviewed explicit entry rather
than an SDK dependency. Preserve that entry when reading native package
identity so matching nested imports remain supported.

* fix(plugins): preserve migrated imports and verify native entry identity

Recognize older native-only receipts by their existing declaration
fingerprint so remote source recipe edits cannot replace migrated imports.
Keep managed npm receipts distinct through their source fingerprints.

Only borrow an ancestor OpenCode package identity when its resolved entry
is the actual registered file. Retain nested and explicit entry support.
Add public two-host migration and mismatching-entry regressions.

* fix(plugins): retain imported ownership through repeated adds

Persist inferred imported ownership when a matching add refreshes the
receipt intent, so later shared recipe changes still preserve local
native installations. Keep the legacy replacement regression aligned
with that ownership contract while retaining removed-intent cleanup.

Reject missing or unstatable absolute OpenCode entries before identity
matching rather than falling back to the file name. Cover both paths
through public Preview and Apply regressions.

* test(plugins): isolate OpenCode adapter fixtures from host config

Keep native registration fixtures inside their fake agent home by setting
XDG_CONFIG_HOME and clearing inherited OpenCode overrides. Ambient config
writes can otherwise leak into config-discovery tests in other packages.

Cover the XDG, file, directory and inline override cases with temporary
config sentinels, while retaining the existing MCP listing expectation.

* fix(plugin): let local imports return to the shared source

Add a local unimport action that removes only this machine’s installation and receipt while preserving the shared source declaration. Keep retained-import guidance visible across matching adds, list, doctor and dashboard consumers.

Avoid idle OMP guidance and unchanged legacy-read locks, preserve localized errors, keep import identity checks offline, and normalize OpenCode drive URLs. Cover the A/B transition and align translations, runbooks and environment cleanup.

* fix(plugin): complete unimport validation and guidance

Reject missing targets before planning local unimports and share per-target eligibility with the wizard. Make native uninstall effects explicit in help and translated docs, preserve structured update guidance, and cover error paths and shell completion.
2026-10-31 04:23:20 +08:00
Rusty Shackleford 5729eee088 feat(project): manage global registrations from the CLI (#603)
Add global project list, show, add, edit, sync and remove so setup scripts
can register repositories without editing YAML or opening the dashboard.
Keep dry runs read-only and report completed work when a target fails.

Reuse the shared project service and sync runners. Include command docs,
translations, completions and regression coverage. Quote overlap hints for
their shell and log partial project syncs consistently with ordinary sync.
2026-10-26 01:38:04 +08:00
Willie b0d87fba28 feat(sync): make prefixed target naming misconfigurations visible (#503)
* feat(sync): make prefixed target naming misconfigurations visible

Prefixed naming (#497) works, but several of its failure modes only showed up
at sync time or gave advice that cannot be followed:

- A collision that only prefixing creates told the user to "rename one in
  SKILL.md", which a tracked skill cannot do, and never said the prefix caused
  it. The hint now names the prefixing and points at renaming the other skill or
  re-tracking the repo with --name.
- `target add` silently wrote mode: copy when the inherited naming is prefixed.
  The CLI now says so.
- A target that resolves to prefixed outside copy mode was reported only by
  sync. status, doctor and target list (plain and JSON) now flag it, and the
  sync/validation and `--skills=true` errors say how to fix it.
- The dim "duplicate skill names (isolated by ...)" line printed on every sync
  even when nothing was wrong, and before a failing sync. Isolated duplicates
  are not a problem, so it is dropped; the website docs still showed an
  outdated form of this output and are corrected in all locales.

* fix(status): flag prefixed-outside-copy in the TUI list and status --json

Codex review of #503 found two surfaces the new check missed:

- The interactive `target list` (the default on a terminal) never read the
  item's naming error, so a prefixed + merge target looked healthy there. The
  list row now marks the mode with "!" and the detail panel shows the fix.
- `status --json` (global and project) builds its target entries directly, so
  scripts got no signal. Each target now carries a `warning` string, matching
  `target list --json`.

* docs(troubleshooting): sync no longer prints a message for isolated duplicates

The collision troubleshooting tip still said sync shows an info message when
filters isolate duplicate skill names. That line was dropped, so the tip now
says sync prints nothing about them. Codex review of #503 flagged the stale
English page and its four translations.

* fix(config): point managed-project naming errors at the project settings

The "set mode: copy on the target" hint is wrong for a target a global
`projects:` entry expands into: it cannot be edited with `target` or under
`targets:`, and the mode lives in the project's skills settings. The hint now
depends on whether the target belongs to a managed project (Codex review of
#503).

The naming/mode check becomes a TargetConfig method so status, doctor and
target list share it, which also lets the hint see the project root. Along the
way: doctor reuses it, the TUI list renders the mode once, and
reportTargetAdded takes a flag instead of comparing a mode string.

* fix(config): hint the project settings for managed-project naming errors

ProjectNamingError (the config-load check for a global `projects:` entry) still
returned the bare naming error, so a project that inherits prefixed with a
non-copy mode got no fix. It now names the project's skills settings, like the
expanded targets do. The built-in skill's sync reference also mentions that
status, doctor and target list flag the misconfiguration before sync.

Found by the second /code-review pass on #503.

* fix(sync): detect prefix collisions from the colliding paths

reportCollisions decided a collision came from prefixing when its name was not
also a duplicate in the source. A tracked skill that joined two ordinary
skills already sharing the name was therefore sent to the "rename one in
SKILL.md" hint, which a tracked skill cannot follow (Codex review of #503).

A collision on a prefixed target that includes a tracked path now gets the
tracked-skill hint, whatever else shares the name. The wording no longer claims
prefixing renamed the skill, since a name that already starts with the repo
name is unchanged.

* fix(sync): use discovered repo metadata for the tracked-skill hint

The collision hint treated any path segment starting with "_" as a tracked
repo, so an ordinary skill under a folder such as org/_drafts (no .git) was
told it could not be renamed and to re-track a repo that does not exist. It now
uses DiscoveredSkill.IsInRepo, the same signal prefixed naming uses.

The prefixed docs also gain the fix for a target a global `projects:` entry
expands into (projects.<root>.skills.mode: copy), since `target` cannot edit
those. Both from Codex review of #503.

* fix(sync): keep both collision hints when targets disagree

The same name can clash on a prefixed target with a tracked skill and on
another target between ordinary skills only. The prefixed flag was OR-ed across
targets, so the second case lost its rename/filter hint. Track both kinds
separately while grouping, and print each hint that applies (Codex review of
#503).

* fix(sync): keep the rename hint inside a mixed collision group

When a tracked skill and two ordinary skills share a prefixed name, re-tracking
the repo fixes only the tracked one; the ordinary pair still clashes and is
excluded. The group now also shows the rename/filter hint when at least two of
its participants are not tracked (Codex review of #503).

* fix(sync): offer filters in the tracked-skill collision hint

Two tracked skills of the same repo with the same name collide after
prefixing, and neither renaming a tracked skill nor re-tracking the repo
separates them. The hint now also names include/exclude filters, so every
collision on a prefixed target has an actionable remedy (Codex review of #503).

* docs(sync-modes): limit the target list claim to targets under targets

target list builds from the config without project expansion, so it cannot
flag a target a `projects:` entry expands into; status and doctor can. The
prefixed paragraph and the built-in skill reference said all three flag it
(Codex review of #503).
2026-10-10 00:00:23 +08:00
Willie 697af5ce3d docs(sync): limit the symlink exemption to filters and naming
Codex review on #499: the conflict pages said "none of these matter in
symlink mode", which reads as if a symlink target and a merge or copy
target on one folder were fine too. Mode still conflicts there; only
filters and naming stop mattering when both targets use symlink.
2026-10-09 01:47:48 +08:00
Willie 8a24ff9211 refactor(sync): treat symlink targets on one folder as never conflicting
A /simplify pass on #499 found the symlink exception too narrow: symlink
mode links the whole folder to the source and reads neither target naming
nor include/exclude, yet two symlink targets with different filters were
still reported as undoing each other. State the rule once (same symlink
mode means same folder contents) instead of exempting only naming, and
resolve the mode with cmp.Or like sync's isSymlinkMode rather than a
local copy of the sync package's resolver. Docs now say none of these
settings matter in symlink mode.
2026-10-09 00:55:53 +08:00
Willie 549d4d8927 docs(sync): describe shared-folder conflicts beyond filters
Codex review on #499: the troubleshooting and doctor pages explained the
conflict as one target adding what the other filters out, and offered
"give both targets the same filters" as a fix. When the conflict comes
from mode or target naming, that fix does nothing and the explanation
doesn't match what happens (entries renamed, links swapped for copies).
Describe the conflict as each sync undoing the other's work and say all
three settings must agree, in English and the four translations.
2026-10-09 00:45:12 +08:00
Willie 7e6649f2c5 docs(sync): say target naming doesn't matter for symlink targets
Codex review on #499: after 588d29c7 the conflict check skips
target_naming when the shared mode is symlink, but the doctor, sync and
troubleshooting pages (and their translations) still said any naming
difference makes shared targets undo each other. That could lead users
to turn off a valid symlink target, so qualify the rule.
2026-10-09 00:41:40 +08:00
Willie 06a0d36536 docs(i18n): say shared-folder conflicts cover mode and naming too
The warning now reads "different settings", but the explanatory prose
around it in the doctor and common-errors pages still described the
conflict as include/exclude filters only. Name mode and target_naming
there as well, in English and the four translated doc sets.
2026-10-09 00:29:08 +08:00
Willie 366fb236c1 fix(sync): flag shared skills folders whose mode or naming differ
Two targets writing one skills folder with different target_naming or
mode undo each other on every sync (flat links vs standard names, merge
vs copy), but only include/exclude were compared, so sync and doctor
fell back to the generic shared-path hint.

Compare the effective mode and target naming too, so an unset value
equals the default it resolves to. The global default mode is not
carried on the target, so SkillsFolderConflicts takes it from its three
callers. The warning now says "different settings" instead of "different
filters".

Fixes #498
2026-10-09 00:28:34 +08:00
Willie 6607b82e2b fix(install): escape submodule diagnostics and match ancestors by filesystem identity
Gitlink paths and .gitmodules URLs come from an untrusted repo, so quote them with %q to keep newlines and terminal escapes out of CLI output. Compare each ancestor of the subdir with the gitlink directory by os.SameFile instead of a byte-length prefix, so case and Unicode-normalization variants that open the same directory are caught.
2026-10-07 02:29:48 +08:00
Willie b7265d6496 fix(install): refuse git submodule paths instead of installing empty dirs
skillshare never fetches submodules, so a gitlink is an empty directory
after any clone. Installing that path reported success with nothing in
it, a path inside it failed with a misleading "does not exist", and
whole-repo discovery dropped its skills without a word.

Refuse a subdir that is or lies inside a submodule, naming the
submodule, its pinned commit and upstream URL, and warn for each
submodule skipped by whole-repo discovery and --track.

Refs #433

Release-As: 0.25.1
2026-10-07 01:58:59 +08:00
Willie 3875c16e26 docs(extras): describe how prepend and append blocks behave and fail
The pages added with the block modes covered what they write, not what
the review fixes made them do. The sharing guide still said sync
overwrites a modified target, which is wrong for a block: sync stops
until the edit is collected or the block is rewritten.

The guide, the extras reference and the built-in skill now cover the
block's Collect and Rewrite choices, block statuses, the target file
dialog, what a mode change removes, how restore treats a block, and
the cases a block target is refused. Common errors gains an Extras
section for the four new messages. The --mode help of extras init,
--add-target and the mode command listed only import among the
single-file modes; it now lists prepend and append too.

Refs #436
2026-10-07 00:59:14 +08:00
Willie 70cb287672 fix(plugin): find the Codex CLI the desktop app ships (#383)
* fix(plugin): find the Codex CLI the desktop app ships

Plugin commands ran the bare name `codex` from PATH, so a machine with only
the Codex desktop app, or a scheduled job started with a minimal PATH,
reported the CLI as missing. The account-only `cli` override did not help:
the default codex target cannot set it, and an absolute path in a config
shared between macOS and Windows is wrong on one of them.

When `codex` is not on PATH, look in Homebrew's folders and the CLI the app
installs (Codex.app on macOS, %LOCALAPPDATA%\OpenAI\Codex\bin on Windows).
SKILLSHARE_CODEX_CLI overrides the search on one machine without touching
the synced config. The missing-CLI error now lists every place searched, in
the CLI and the dashboard.

Refs #338

* docs(plugin): note where Skillshare finds the Codex CLI

The plugin reference and the sharing guide still said every native CLI must
be on PATH, and the built-in skill told agents a missing CLI has no
fallback. Codex now has one, plus a machine-local override that agents
should prefer over a path in a shared config.

Refs #338

* fix(plugin): look for the Codex CLI inside ChatGPT.app

Since the Codex desktop app merged with ChatGPT, macOS installs it as
ChatGPT.app, so an app-only Mac with a minimal PATH still reported Codex as
missing. Try ChatGPT.app before Codex.app in /Applications and
~/Applications, the order Codex's own desktop-app finder uses.

Refs #338

* fix(plugin): run the packaged CLI entrypoint of the ChatGPT app

ChatGPT Desktop 26.924 removed Contents/Resources/codex and ships the CLI
at the entrypoint its package manifest declares, codex-cli/bin/codex, so a
current app-only Mac still reported Codex as missing. Try that entrypoint
first in each app bundle and keep the old path for earlier builds.

Refs #338

* fix(plugin): find the Codex CLI from the Windows installer

The official PowerShell installer puts codex.exe in
%LOCALAPPDATA%\Programs\OpenAI\Codex\bin and adds it to the user PATH. A job
started without that PATH missed it, the same gap Homebrew's folders cover
on macOS. Try it before the desktop app's copy.

Refs #338

* fix(plugin): keep an account's cli even when it is codex

The Codex search ran whenever the executable was the bare name codex, so an
account that set cli: codex could get SKILLSHARE_CODEX_CLI or the app's CLI
instead, against the documented rule that an account's own cli is kept.
Search only when no account cli is set.

Refs #338
2026-10-04 15:16:14 +08:00
Willie d78e7ce09a feat(cli): redesign init and give every command one output style (#360)
* fix(install): omit the empty audit section in dry-run

A dry-run skips the security audit, yet the single-skill path still printed
the "Audit Findings" heading with nothing under it, which reads as if the
audit ran and found an empty result.

* feat(init): ask first, confirm a summary, then write

The old init asked nine questions in three input styles and wrote files as
it went, so cancelling midway left a half-built setup, and detection created
tool folders even under --dry-run. Connecting a second machine to an
existing repo was only offered at the very end, and the built-in skill
defaulted to "no", which read as "not recommended" (#200).

init now collects every answer into a plan, shows a summary with Yes /
Change settings / Cancel, and writes nothing until confirmed. Esc cancels
cleanly. A "Connect my existing skillshare repo" path checks the repo
before writing, detects its layout, prefers the repo version of same-name
skills and keeps local-only ones for the next push. The built-in skill is
installed by default, and the first sync runs at the end so the tools work
right away. Prompts use one inline huh-based component with theme colors.

Without a terminal (CI, scripts, AI agents) init now applies the same
defaults as pressing Enter and prints each decision with the flag that
changes it, instead of silently doing less; init -p and --discover add the
detected tools. Output that is not a terminal is plain text.

BREAKING CHANGE: non-interactive `init` now enables git, installs the
built-in skill and selects every detected tool; pass --no-git, --no-skill,
--no-targets or --no-copy for the previous minimal setup. Piped or
redirected output no longer contains ANSI colors; use --json where offered
for machine-readable output.

Refs #200

* docs(init): show the new init flow and the connect-a-repo path

The getting-started page still described the old four-question wizard with
a screenshot of it, the second-machine guide never mentioned the new
"Connect my existing skillshare repo" choice, and the recipe told users to
run pull and sync after init even though init now does both.

Replace the screenshot with ones from the new flow, describe the questions,
summary and cancel behavior, and explain what connecting a repo does before
and after confirmation. The devcontainer example gains --no-git because
init without a terminal now turns git on by default.

Refs #200

* feat(devcontainer): seed fake tools and a repo with ssenv --seed

Trying init by hand needed several manual steps to fake installed AI tools
and a skills repo to connect. `ssenv create --seed` (and `ssnew --seed`)
now creates claude/codex/cursor directories with a few skills and a local
bare repo at ~/remote/skills.git, so both init paths can be tried at once.

Refs #200

* fix(ui): skip the logo on 16-color terminals and hide the cursor while it plays

`docker exec -it` sets only TERM=xterm, which reads as 16 colors: the logo
was mapped onto the terminal's own palette and its fade-in collapsed into a
few flickering cells. Below 256 colors the banner now prints only its text,
and the devcontainer sets COLORTERM=truecolor.

The visible cursor also jumped along the logo's left edge while frames
redrew in place. It is hidden during the animation and restored on exit,
including Ctrl+C.

Refs #200

* style(ui): color the question mark in prompts

The uncolored "?" before each question read like a stray character. It
now uses the accent color of the "›" cursor.

Refs #200

* fix(init): name the root git scope by what it versions

"everything" suggested plugins, MCP servers and hooks were versioned too,
but they live in config.yaml, which the root scope gitignores. The option
and summary now say "skills, agents, extras" and note that those settings
stay in each machine's config.yaml.

Refs #200

* feat(init): show --discover in the new init style

--discover still printed the old header, "agent(s)" counts and "+ name"
lists next to the new prompt. Global and project discover now share
init's answered rows (Tools, Config) and a Next line, and call the
targets "AI tools" as init's banner does.

Refs #200

* feat(init): replace the pixel logo with a SKILLSHARE wordmark

The half-block logo looked stretched on terminals with tall line height
and turned to mush when shrunk to fit. init now opens with a three-line
pixel wordmark, SKILL in blue and SHARE in gold, that lights up from left
to right, followed by the version and tagline on one dim line. The
generated logo data and its generator script are gone.

Without a terminal, without color, below 256 colors or on a narrow
terminal, the banner still prints a plain "skillshare vX" line.

Refs #200

* refactor(init): label the chosen tools "Targets"

init called them "Tools" while the rest of the CLI, the config file and
the `target` command call them targets. The answered rows and the summary
now say "Targets", the same label the other commands will use. Sentences
that describe what was detected ("Found 3 AI tools") stay as they are.

The docs tables, the First Sync steps and both init screenshots are
updated to match.

Refs #200

* feat(cli): ask yes/no questions with the inline prompt

uninstall, trash empty, extras remove, target add, collect, update,
upgrade and audit each printed their own "[y/N]:" line and parsed the
answer by hand, while init already used the inline Yes/No prompt. They
now share it: esc answers no, and a declined question prints one dim
"Cancelled. Nothing was …" line, as init's cancel now does too.

Without a terminal the prompt reads one line from stdin instead, so
piped answers such as `echo y | skillshare uninstall x` keep working.
It reads byte by byte so a second question still gets its own answer.

Refs #200

* feat(sync): report each target on one aligned row

Sync printed a ruled header, a "Backing up" block and a "name: merged
(43 linked, 0 local, 0 updated, 0 pruned)" line per target, so the
counts that changed were hard to find among zeros. It now follows the
init style: one row per target with only the non-zero counts, a single
Backup row, and a closing line with the duration. `sync --all` names
its Skills, Agents and Extras blocks and no longer explains how to set
up extras when none are configured.

The non-TTY text changes with it; `--json` stays the stable interface
for scripts. Tests match rows through the new AssertRowContains helper.

Refs #200

* feat(status): show targets as one table

Status printed each target as a header with indented skills and agents
lines full of bracketed modes and zero counts, and the audit policy as
four lines of uppercase labels. Comparing targets meant reading every
block. Each target is now one row with a skills and an agents column,
a single line names the modes in use, and audit and version take one
line each. Global and project mode share the renderer, so project
paths read relative to the project root.

Refs #200

* feat(install): report each step on one aligned row

Install printed a logo, a box-drawn tree, "Next Steps" bullets and a
separate "Audit Findings" block, so the result was hard to find. It now
uses the same rows as sync and status: Source, Audit and Install with
the destination folded to ~, then a closing line and a Next block.

Spinners write through a gate that Stop closes before clearing the line.
pterm's render goroutine checks IsActive and then writes, so a fast step
such as install --dry-run left "Copying files..." stuck in front of the
next line.

Refs #200

* feat(uninstall): confirm against one line and point at undo

Uninstall opened with a boxed header and Name/Path lines, and closed
with the trash folder path and a "Next Steps" bullet. Now one line names
the target, its folder and what it holds; the result is a single
"Uninstall x → trash, kept 7 days" row; and Next offers sync, the trash
restore command that undoes it, and the reinstall command when the
skill came from a remote source.

A batch run with --force or --dry-run no longer lists the targets twice,
since there is no question for the list to support. Mixed batches are
counted as items, not targets, which already names the AI tools.

Refs #200

* feat(update): report each skill or repo on one Update row

Update opened with an "Updating" header, the full source path and a
"0 tracked repo(s), 1 skill(s)" line, then printed a Changes box and two
success lines before "Next Steps". A single update is now an Update row
(source or commit count, time), the commits it pulled in dim text, the
Audit row, and Next. A batch ends with the audit result and one closing
line that leaves out zero counts.

Progress bars now clear themselves when they stop, like spinners, so a
finished batch no longer leaves "[3/3] ... 100% Done" behind.

Refs #200

* feat(check): list what needs attention and close with one line

Check opened with a header, the full source path and an item count,
counted skills with updates without naming them, and ended with two
"Run ..." hints. It now prints one row per repo, skill or agent that
needs attention (behind, update available, stale, failed), a closing
line that leaves out zero counts, and the update command under Next. A
single-name check is one row, like update.

Refs #200

* feat(push,pull): report commit, push and pull as aligned rows

Push and pull opened with a header and closed with "Push complete" or
"Pull complete", so they never said what they committed, where they
pushed, or what a pull brought in. Push now prints a Commit row (file
count and message) and a Push row naming the upstream branch, never the
remote URL since it can carry credentials. Pull prints a Pull row with
the commit and file counts and the commits themselves, as update does
for a tracked repository, before the sync output. Dry runs list the
changed files as ~ + - instead of raw porcelain codes, and error hints
are dim notes instead of info lines.

Refs #200

* feat(upgrade): report the CLI and the skill on one row each

Upgrade opened with the logo and printed a tree of steps per part
(current version, latest version, status) ending in "Already up to date
✓". Each part is now one row, such as "✓ CLI  v0.22.0 → v0.23.0 · 3.1s"
or "✓ Skill  v0.23.0, already up to date", with spinners that clear.
Sync is offered under Next only when the skill changed, and the star
request is a dim line at the end.

Refs #200

* feat(new): report the created skill on one row

New printed a "New Skill Created" header, the full path, and numbered
"Next steps" that told the user to edit the file and run sync. It now
prints "✓ Created  ~/…/SKILL.md", the folders a pattern added, and sync
under Next. A dry run shows the same row, a Preview section with the
template, and the dry-run line.

Refs #200

* feat(trash): list items and restores as aligned rows

The plain trash list printed each item as an info line with its size and
age in parentheses under a "Trash" header, and restore printed two
success/info lines plus a "Next Steps" label. The list is now rows of
name, size and age with one closing count, and restore is one row
naming where the item went back, with sync under Next. An item trashed
under a minute ago reads "just now" instead of "just now ago".

Refs #200

* feat(collect): list local items and results as aligned rows

Collect opened with a header, listed local items as "[target] path"
list items under a second header, then printed a third header before
the per-item results and a metric summary line. It now lists each local
item as a row (name, target, path), asks the inline confirm, prints one
row per result and closes with "Collected N skills" plus sync and,
when the source is a git repository, commit under Next.

Refs #200

* feat(hooks): show hooks and their changes as aligned rows

Hooks printed "Hooks source: <path>" as an info line, statuses through
the fixed-width Status helper, and results as sentences ending in
"Run 'skillshare hooks sync' when ready." Hooks and Agent file changes
are now rows, with conflicts marked as failures and inactive outputs as
warnings, saves and applies close with one line, and the next command
sits under Next. The list's "Pending sync" section no longer shows
entries that are already in place.

Refs #200

* feat(mcp): show servers, changes and checks as aligned rows

MCP printed "MCP source: <path>" as an info line, plan changes through
the fixed-width Status helper, results as sentences that named the next
command inline, and check summaries as "2 server(s) checked: 1
error(s)". Changes and parked servers are now rows with conflicts
marked as failures, saves and applies close with one line and Next, and
check marks each server with its findings beneath and closes with
"Checked 2 servers: 1 error". The Status helper had no callers left and
is removed.

Refs #200

* feat(plugin): show packages, plans and results as aligned rows

Plugin text output was raw "name · target · id · state" lines with
"Warning:", "Includes:" and "Revision:" prefixes, and the list walked a
map so packages came out in a different order each run. Packages,
discovered candidates, planned changes and results are now rows sorted
by name, marked by state (registered, not installed, pending, blocked,
failed), with details as dim notes and the dry-run line after a
preview. JSON output is unchanged.

Refs #200

* feat(audit): replace header and summary boxes with rows

Audit framed its context in a header box (mode, path, block rule,
policy), numbered batch results "[1/2]", printed per-skill verdicts as
"→ Aggregate risk / Block decision" lines, and closed with a Summary box
that listed every count including zeros. The context is now one title
line with a dim note, flagged skills are aligned rows with their highest
severity, the summary leaves out zero counts, and the run closes with
one line saying whether anything was blocked and by which severity,
followed by the command to see the first blocked skill's findings.

The progress bar no longer writes its final frame when stdout is not a
terminal; that frame had no newline and ran into the next line.

Refs #200

* feat(audit): show audit rules as aligned rows

The rules list was a fixed-width table framed by 90-character dividers
with a "(N rules: N enabled, N disabled)" footer, and rule changes were
sentences like "Set severity for X → HIGH". Rules are now rows keyed by
ID with a colored severity and the pattern dimmed, disabled rules dim
as a whole, the list closes with a count that names disabled rules only
when there are some, and each change is one row.

Refs #200

* feat(search): drop the logo and tree, show results as rows

Search opened with the ASCII logo, drew its progress as a ├─/└─ tree,
listed results under a column header with dividers, and ended installs
with "Run 'skillshare sync' to distribute to all targets". Results are
now aligned rows with the source, stars or risk, and the description
and tags beneath; a single install reports the same Install row as
`skillshare install`; batch installs list only failures before one Done
line; and sync and audit sit under Next. Login and rate-limit problems
name the command that fixes them. Non-terminal output no longer prints
a "name: installing..." line per skill.

Refs #200

* feat(backup): show backups and restores as rows with one closing line

Backup and restore opened with headers, announced dry runs with a
warning before doing anything, summarized with an operation box, and
followed a backup with a "Recent backups" list. Targets now back up in
name order as rows with folded paths, runs close with one Done line
(and Next restore), listings are rows keyed by timestamp or path with a
total, and dry runs end with the shared dry-run line. Cleanup reports
how many backups remain instead of a separate "Current" line.

Refs #200

* feat(help): one line per command, subcommands in each command's help

The top-level help opened with the ASCII logo and listed about 70 lines
across ten uppercase sections plus 15 examples, so it did not fit a
screen, yet it left out analyze and the common options. It now lists
each command once in six groups with the common options, and points to
`<command> --help` for subcommands. The mcp, plugin, hooks and extras
pages use the same layout and keep all their content.

A mistyped command prints one error with the closest command instead
of the whole help, a lone option such as --no-tui shows the help, and
`skillshare version` prints one line.

Refs #200

* feat(extras): show extras and their changes as rows with Next

Extras printed a header, "→ name" lines with ad-hoc colored marks
(including ✗ for targets that were only waiting for a sync), and ended
each change with a sentence naming the next command. The list now shows
each extra as a bold name over aligned target rows (! for drift or not
synced) and closes with a count and, when something is pending, Next
sync extras. Init, collect, add/remove target, mode and source changes
close with one Done line, details become notes, and dry-run collect
ends with the shared dry-run line.

Refs #200

* feat(target): show targets as sections and rows with Next

Target info and the plain list printed "Key:" lines at two indent
levels, with "(none)" for every unset filter, and remove printed
"Backing up" / "Unlinking" headers with one line per step. Info now
shows the name over Skills and Agents sections with aligned rows, the
list gives each target one row per resource with details dimmed, and
empty filters are left out. Remove reports one row per target (plus
its backups) and closes with a Done count; dry runs say what would
happen per target and end with the shared dry-run line. Skills on/off,
add and mode/naming/filter changes close with Done and Next.

Refs #200

* feat(doctor): report checks as aligned rows and end with Next

Doctor opened with the ASCII logo, split its report under divider
headers, mixed ✓/→/! lines with full paths and "(s)" counts, listed
targets in random map order, and ended with a bare warning count that
left the fix to scattered "Run:" hints. Checks now print as aligned
rows under bold sections (Environment, Targets, Extras, MCP/hooks/
plugins, Storage, Version), paths fold to ~, targets are sorted with
one row per resource, and the report closes with a Done line plus up
to three Next commands collected from the checks (sync, sync agents,
sync hooks, upgrade, ...). The --json output is unchanged.

Refs #200

* feat(hub): drop the logo and report hub changes with Done

hub index opened with the ASCII logo and a tree of spinner steps, then
repeated the result as "→ Mode / Skills / Output" lines with the full
path. It now shows one spinner that clears itself and a Done line
naming the folded output path, skill count and duration, with the
index contents as a note. hub list shows aligned rows with the default
and built-in hubs marked in dim text instead of a "*" column, and the
add, remove and default commands close with a Done line.

Refs #200

* test(install): match the shared dry-run line in online tests

The online-tagged install tests still looked for the old "dry-run"
banner, which install no longer prints since the restyle. They are
skipped by default, so the mismatch only showed under -tags online.

Refs #200

* fix(target): align remove rows on target names only

The label column was sized for "<name>-agents" so an agents backup
could fit, which left a wide gap on every row when no agents were
backed up. The agents backup row now uses the target name too and says
"agents backed up", so the column fits the names.

Refs #200

* fix(update): list each item in a batch dry run

A batch dry run only said "Would update N skills". Off a terminal the
names leaked out through the progress bar's title lines, but on a
terminal those lines clear, so the dry run never said which skills or
repos it would touch. It now prints one Update row per item, as the
single-item dry run does.

Refs #200

* fix(ui): keep the progress bar silent off a terminal

Off a terminal the bar printed "Title (0/N)", every title change and
every phase header as permanent lines, which a terminal shows only as
a frame that clears itself. Audit left a stale "Scanning skills (0/7)"
line, and scripts saw different content than a terminal. The bar now
prints nothing off a terminal, like the spinner.

Refs #200

* fix(audit): avoid a double blank line before Summary

The audit header ends with a blank line and Summary added its own, so
a clean scan with no result rows showed two blank lines in a row. The
Summary title no longer adds one; the result rows add it when present.

Refs #200

* fix(mcp): drop the blank line above "Saved the MCP source"

A save with no backup or migration notes printed a blank line with
nothing above it, so mcp add and mcp edit opened on an empty line.

Refs #200

* fix(doctor): stop repeating the extra's name in its findings

Extras findings printed "rules  rules → /home/me/.claude/rules: 1
file(s) out of sync": the row label already names the extra, the path
was not folded to ~, and the count used "file(s)". The rows now start
at the arrow, fold the path and pluralize the count. JSON details keep
the extra's name so each line still stands alone.

Refs #200

* fix(doctor): show integrity issues as rows under Integrity

Tampered skills and missing hashes printed as free "! Skill integrity:
N skill(s) ..." lines after the verified row, breaking the aligned
Environment rows. They now sit under a single Integrity row, which
turns to ! when any skill has an issue.

Refs #200

* fix(doctor): pluralize the Skillignore and Trash rows

The rows read "1 patterns, 1 skills ignored" and "1 item(s) (50 B),
oldest <1 day". They now read "1 pattern, 1 skill ignored" and "1 item,
50 B · oldest under a day". The JSON messages keep their wording, since
scripts may match on them.

Refs #200

* docs: show the restyled output of batch 3 commands

The reference pages still showed the old output of upgrade, new, trash,
collect, audit, search, backup, restore, extras, hub, target and doctor:
divider headers, arrow-prefixed lines and "(s)" plurals. The examples
now match what the commands print, in all five locales, and the doctor
check table uses the new row labels.

Refs #200

* feat(trash): let trash empty skip its confirmation with --force

Scripts had no way to empty the trash: off a terminal the confirmation
reads stdin and cancels on EOF. --force (-f) skips it, as it does for
uninstall and extras remove.

Refs #200

* fix(doctor): show source, link and target problems as rows

Missing sources, unsupported links, folders without SKILL.md, unknown
skill targets, bad include/exclude patterns and broken symlinks printed
as free "✗ Source not found: …" lines between the aligned rows. They
now use the row of the check they belong to, and broken symlinks or a
missing source add a Next suggestion.

Refs #200

* fix(ui): leave out durations that would read 0.0s

Fast commands ended with "· 0.0s", which says nothing. Every result line
now formats its time through ui.Took, which init already used for its
steps: durations under 0.05s are left out.

Refs #200

* fix(ui): print dev builds without a v prefix

Version labels were built as "v" + version everywhere, so a dev
build printed "vdev". VersionLabel adds the prefix only when the
version starts with a digit, and the logo, help header, version
command and upgrade output share it.

Refs #200

* fix: pluralize category and drop "just now ago"

The checklist status bar appended "s" to its item name and printed
"categorys". The trash TUI formatted ages with its own helper that
added "ago" after "just now". plural now handles consonant + y,
and the trash TUI uses the shared timeAgo, which makes formatAge
unused.

Refs #200

* fix(target): drop the parenthesized counts in the plain list

The plain target list printed "merged (43 shared, 0 local)" while
target info and doctor print "merged · 43 shared" with zero counts
left out. The sync summary now returns both forms from one scan, so
the TUI and --json keep their existing text and the plain list
matches the other commands.

Refs #200

* test(backup): make the agents backup test back something up

The test only synced agents, which become symlinks into the source
and are skipped by backup, so it passed without any backup being
written. It now adds a target-local agent and checks that the file
lands in the backup.

Refs #200

* refactor(cli): render every command's --help with printHelp

About forty help pages were hand-aligned raw strings with "Usage:",
"Options:" and "Examples:" headings, while hooks, mcp, plugin, extras
and the top-level help already used printHelp. They now share it, so
headings, option order (short flag first) and alignment match across
commands. Examples align on their own column so long commands no
longer push option descriptions to the right, and "--help, -h" rows
are dropped as on the converted pages.

Refs #200

* feat(enable): print enable and disable results as rows

enable/disable still used the old "Disabled: x (added to .skillignore)"
line plus a "Run skillshare sync" sentence. They now print one row per
pattern, a Next hint after a change, and the dry-run closing line,
like the other restyled commands.

Refs #200

* fix(sync): pluralize the leftover cleanup note

Project sync printed "Cleaned 1 leftover skill(s)". The note now
uses the singular or plural noun, and the sync docs show it as the
dim note it is instead of an arrow line.

Refs #200

* fix(cli): drop the arrow info lines left in install, update and sync

These commands were restyled, but about fifty messages still went
through ui.Info, which prints a leading arrow, and several said
"skill(s)" or "item(s)". Hints now print as dim notes, empty results
("No agents found") as closing lines, follow-up commands as Next,
and counts use the singular or plural noun.

Refs #200

* fix(cli): tidy small leftovers found in the recorded output

doctor printed "0 minutes ago" for a fresh backup and an ASCII arrow in
the Update row, unlike trash and upgrade, which say "just now" and
"v1.2.0 → v1.3.0". The "bring the Targets up to date" hint capitalized
a word mid-sentence, and search --list showed hub sources under the
home directory as a cut-off absolute path instead of folding it to ~.
JSON messages keep their wording.

Refs #200

* fix(search): fit a home-folded source path in the list

Folding the home directory to ~ was not enough: a typical local hub
path such as ~/.config/skillshare/skills/frontend/react is 42
characters, so the 40-character cap still cut it. Fifty characters
next to the 24-character name column stays within 80 columns.

Refs #200

* feat(list): print the plain list with rows and a closing count

The --no-tui list still used the old header with a divider and an arrow
on every skill, so it looked unlike every other restyled command. Skills
now line up in one column under their group, tracked repos use the
✓ / ! marks, and the list closes with a count split by tracked, remote
and local (zero counts left out). Project mode keeps its scope as a dim
"· project" after the title.

Global and project had copied the same plain-output code; both now call
printSkillList. The loading spinner clears itself instead of leaving a
"Loaded N skills" line.

Refs #200

* fix(cli): show help for subcommand --help instead of running it

target add/remove/list, trash list/empty and hub list/remove passed
--help through as an argument, so they ran the command, failed on a
target or hub named "--help", or rejected the flag. tui on --help even
switched the TUI on. Each now prints its command's help page.

The tui status and toggle lines also move to the row and Done style.

Refs #200

* feat(diff): print differences as rows and close with next steps

The plain diff still printed a Summary line, divider headers, arrow
hints and per-target "scanning" lines when output was not a terminal.
Each group of targets now lists one row per kind of change ("New  a,
b"), targets in sync share a single ✓ row, extras use the same rows,
and diff closes with a count and up to three commands. The suggested
sync command follows what differs: sync, sync agents, sync extras or
sync --all.

Agents no longer show as "New 1 skill", because rows name the change
rather than counting skills. "skillshare diff all", listed in the help,
failed with "target 'all' not found"; it now diffs everything, the
same as no argument.

Refs #200

* test: sync the install warning summary and gofmt two status tests

The "6 findings" wording changed in an earlier commit, but the unit
test under cmd/ still expected "6 finding(s)": scripts/test.sh and
make check only run ./internal and ./tests, so the cmd tests never ran.
Two status tests also had comment alignment gofmt rejects, which fails
make check's fmt-check.

Refs #200

* test: run the cmd unit tests in scripts/test.sh

CI runs go test ./cmd/skillshare/... ./internal/..., but the local
runner behind make test and make check only ran ./internal/..., so a
stale assertion in cmd/skillshare passed locally and would only fail
in CI.

Refs #200

* feat(cli): restyle commit and analyze output

commit and analyze were the last git and inspection commands still
printing the old header and table layouts. They now use the same rows,
Done line, and Next hints as push and pull, so a commit reads like the
commit row of push, and analyze shows each target group as a bold name
with aligned token rows instead of a boxed table.

Refs #200

* feat(log): show entries as rows and fold the log path

The plain log view still opened each section with a boxed header that
printed the absolute log path, then a TIME | CMD | STATUS table. Entries
now read like every other command: a status mark, the command, when it
ran and how long it took, with details indented beneath. The log path is
folded to ~ and moves to a dim footnote.

log --stats drops its divider and ends with one summary line. It and
the TUI stats panel said "just now ago" for a fresh entry; both now use
timeAgo, which already handles that case.

Refs #200

* feat(cli): restyle completion, ui and leftover arrow lines

completion --install, ui start/stop and a few notices still printed
arrow info lines with absolute paths. They now end with a Done line,
fold paths to ~, and give config-file lines their own bold heading so
the lines to paste read apart from the hints. The empty extras TUI now
says the same thing as extras list.

Refs #200

* feat(init): report git changes on an existing setup as rows

init --remote and init --git-root on an existing setup still printed
arrow lines with absolute paths and spinner results in a different
voice. They now print aligned Git, Remote, Pull and Git root rows like
a fresh init, end a dry run with the shared Dry run line, and give the
choices after a remote check as Next commands.

A source repo the user created before init had no fallback identity,
so on a machine without git config the follow-up commit failed and
dumped git's whole "Please tell me who you are" message. The existing
repo now gets the same local fallback a new one does.

Refs #200

* feat(doctor): warn when a newer built-in skill is published

status already compared the skillshare skill with the published one,
but doctor only printed the local version, so a run meant to find
problems called an old skill healthy. doctor now fetches the published
version alongside the CLI update check and suggests upgrade --skill.

Both commands share a semver comparison. status compared with !=, so a
skill ahead of main (a dev build) was reported as having an update.

Refs #200

* fix(cli): count batch audit warnings in words and clear progress spinners

The batch install and update audit summary still printed "2 skill(s)"
and "warning(s)" after the rest of the output switched to "1 skill" /
"2 skills". uninstall and agent update also left "Found N skills" and
"Check complete" behind, progress messages the restyle clears.

Refs #200

* fix(cli): say so when diff or analyze has no targets

With no targets configured, diff reported "No differences" and analyze
printed only its "Add -v" hint, both reading like a healthy result.
They now say no targets are configured and suggest target add, as
target list does.

Refs #200

* fix(diff): align values across target sections

Each target section sized its labels on its own, so a section with
"Local only" started its values two columns later than one with only
"New", and the list read ragged. All sections now share one width.

Refs #200

* fix(doctor): count built-in skill warnings in the summary

The skill rows (not found, missing version, newer version available)
were marked as warnings and counted by --json, but never reached the
text summary, so doctor could print "! Skill not found" and close with
"All checks passed". The all-good integration test only passed because
of this; it now installs the built-in skill it needs.

Refs #200

* fix(init): stop writing a git identity into existing repos

On a repo the user created, init stored skillshare@local in the repo
config so its one commit would work. That setting outranks --global,
so the advice we printed never took effect and later pushes went out
as skillshare@local. The commit now gets the fallback through env
vars only. The note for repos init creates names the repo-level
command that actually overrides it.

Dry runs also wrote .gitignore into existing repos while closing with
"nothing was written", and warned about --no-git when it was not
passed; both now only describe what would happen.

Refs #200

* fix(cli): tell "no targets" apart from "nothing reaches them"

diff and analyze said "No targets configured" and suggested adding one
whenever there was nothing to show, including when targets exist but
have skills turned off or no skill is meant for them.

Refs #200

* fix(log): drop the trailing separator on instant entries

Entries with no recorded duration ended in a dangling " · ". Also
removes the formatRelativeTime alias the stats restyle left unused;
its test now covers formatDurationShort directly.

Refs #200

* docs: match tui, project list and log examples to the real output

The tui and project list examples used label widths the CLI does not
print, and the plain log example claimed to show non-TTY output, which
joins each entry's details on one line.

Refs #200

* perf(version): cache the published skill version for a day

doctor and status asked GitHub for the latest skill version on every
run, adding up to 3 s when offline. They now reuse the answer for 24
hours, the same interval the CLI update check caches for. upgrade
--skill still fetches fresh and records what it got.

Refs #200

* perf(server): reuse the cached skill version on the dashboard

The version endpoint fetched the published skill version on every
call, like doctor and status did, so it now shares their 24-hour
cache. It also treated any difference as an update, offering a
"newer" skill to anyone running a local build ahead of main.

Refs #200

* test(redteam): match the restyled update --diff heading

update --diff now titles its file list "Files changed" in sentence case,
like every other section, so the check for the list looked for the old
"Files Changed" box title and failed although the list was there.

Refs #200

* test(cli): keep /tmp fixtures unfolded where HOME is /tmp

scripts/test.sh now runs the cmd unit tests, so the docker sandbox runs
them too, with HOME=/tmp. shortenPath then folds the /tmp fixtures in
four tests to ~ and their exact-path checks fail. The tests now point
the cached home elsewhere while they run.

Refs #200

* fix(init): find skills/ in a repo that holds nothing else

The check for a skills/ folder ran only when the repo root had no skill
folders, but it counted skills/ itself as one, so it never ran. A repo
with only skills/ became the source as a whole, one level too high.

Refs #200

* fix(init): keep the skills git scope for a custom source

With a remote that has no skills yet, init defaulted to versioning the
whole skillshare folder. For a --source outside that folder it holds
none of the user's skills, so the commit and every later push carried
nothing while init reported the remote as linked.

Refs #200

* test(sync): check only the Agents section for updated agents

The restyle turned the old "0 updated" check on the agent summary into
"no 'updated' anywhere", which also covered the Skills section. On
macOS the first project sync reports the skill as updated there, so
the test failed on something it was never meant to check.

Refs #200
2026-10-03 21:43:35 +08:00
Willie ed2f1c0675 docs: explain what cross-machine sync carries for plugins, MCP and hooks
Users syncing Codex setups between macOS and Windows with push/pull
found that plugins did not follow, imports would not reinstall on the
second machine, and installed plugins never updated. The pages implied
pull syncs everything, but plugins, hooks and MCP live in config.yaml,
which no git_root scope tracks, and pull never runs sync --all or plugin
sync.

Document what each scope carries, the extra sync steps after pull, how
to version MCP through sources.mcp in a root-scope repo, why plugins
must be re-added from an HTTPS source, and what stays per machine. Add
troubleshooting for a CLI missing from PATH and a missing native
marketplace, and pin heading anchors so translated pages link correctly.
2026-10-02 22:22:15 +08:00
Willie 5530aaebe5 docs(sync): explain the warning for targets that undo each other's sync
sync now names two targets that write one folder with different filters,
but nothing told users searching for "sync keeps showing the same
changes" why it happens or how to fix it. The troubleshooting page covers
the symptom, the sync filter notes say shared folders need matching
filters, and the built-in skill points agents at the printed command.
2026-09-29 12:13:15 +08:00
Willie 11ccf30a18 docs(git): describe how pull and push handle two machines
The pages still told users to inspect conflicts with git status and to
fix diverged tracked repos with git pull --rebase, but pull now merges
diverged history, resolves .metadata.json conflicts on its own, and
undoes the merge on any other conflict, so those steps no longer match
what happens. Also documents the Git Sync page fetch, the Pull count,
and the push_rejected API error in every translated locale.
2026-09-25 03:00:15 +08:00
Willie 7d26726a5e feat(targets): split antigravity-cli into its own target
The Antigravity CLI (agy) reads ~/.gemini/antigravity-cli/skills and
never the app's ~/.gemini/config/skills, so treating it as an alias of
antigravity synced skills to a directory it does not read. Give it its
own targets.yaml entry with the correct path.

A path-less `antigravity-cli:` config entry also failed validation,
because DefaultTargets() is not alias-aware; as a real target it now
resolves to the default path.
2026-09-21 02:36:06 +08:00
Willie 4415c7a75a docs(website): pin explicit anchors on headings that will be retranslated
These headings mix prose with technical terms (e.g. '.skillignore
(Optional)', 'Git Authentication', 'Target include/exclude filters')
and are referenced by anchor fragment from other pages. Translating
the prose changes the auto-generated slug and breaks the link, so
pin the current slug explicitly before the next translation batch.
2026-09-20 11:21:14 +08:00
Willie 9143b467e0 fix(targets): split gemini out of antigravity and correct global path
Antigravity and Gemini CLI read different global skill directories, so
folding gemini into antigravity as an alias made one of them wrong for
every user. Antigravity loads ~/.gemini/config/skills; Gemini CLI loads
~/.gemini/skills. Restore gemini as its own target so both resolve
correctly.

Also document that Antigravity's skill scanner skips symlinks entirely
(surfacing as "Incorrect function" on Windows, silent absence elsewhere)
along with the two available workarounds.

Closes #255
2026-08-02 22:38:56 +08:00
Willie 262da080c0 docs(backup): document backup scope and disk space, fix stale paths
The backup docs claimed per-skill symlinks were "resolved and followed" and
their real content backed up, which is now the opposite of what happens.

Adds a Backups & Disk Space section contrasting the three mechanisms that are
easy to conflate — .gitignore (git only), ignore: (sync), and backup (local
target content) — plus an ENOSPC troubleshooting entry, since disk space had
no coverage anywhere in troubleshooting despite being how this surfaced.

Also corrects two long-standing errors: the backup location was documented
under ~/.config in the built-in skill reference and in a `backup --list`
example, but backups live in the XDG data dir (config.DataDir()); and the
built-in skill claimed backup was global-mode only, when project mode does
support agent backups.

Refs #252
2026-07-30 00:55:47 +08:00
Willie 10d94a3542 fix: suggest install for missing tracked repos 2026-06-10 15:54:23 +08:00
Willie def12c51ca chore: update docs 2026-05-30 19:23:12 +08:00
Willie b1907cd611 docs: document custom project source directories
- Add 'Custom Source Directories' section to project-skills.md covering
  the sources map, common layouts, and constraints (no target alias,
  external paths skip gitignore, .skillshare/ for ops dirs, init seeds
  default paths).
- Add troubleshooting entries for the two new error classes: malformed
  project config (fail-closed) and source/target path overlap.
2026-05-20 18:39:16 +08:00
Willie 806045d392 docs(agents): expand docs + skillshare SKILL.md for agent workflows
- skills/skillshare/SKILL.md: mention agents commands/flags in description
- website: document agents source dir, agent backup/restore, ignores,
  file structure, config fields, and project-mode agent rules
2026-04-11 00:41:29 +08:00
Willie 6a94c69e47 docs: update docs and changelog for v0.17.1
Add documentation for new features (UI theme system, init --subdir),
bug fixes (collect .git skip, actionable git errors), and release notes.
Update CHANGELOG.md, website changelog, and 6 doc pages.
2026-03-13 14:09:40 +08:00
Willie 272735c607 feat(install): detect SSL certificate errors and show actionable guidance
When git operations fail due to SSL certificate issues (self-signed certs,
internal CAs), the error message now suggests GIT_SSL_CAINFO, GIT_SSL_NO_VERIFY,
and SSH as alternatives instead of showing raw git stderr.

Env vars like GIT_SSL_CAINFO are already inherited via os.Environ() in
gitCommand() — the actual gap was error detection and user guidance.
2026-03-05 02:13:21 +08:00
Willie caa525b8aa feat(website): complete website revamp — Diátaxis IA, blog, recipes, quickstarts
Restructure the entire documentation site following the Diátaxis framework
(Learn / How-to / Understand / Reference) with new content across 110 files.

## Information Architecture (M1)
- Move all docs to Diátaxis directory structure (learn/, how-to/, understand/, reference/)
- Add client-redirects plugin for old URL compatibility
- Rewrite sidebar, navbar, and footer to match new IA
- Update all internal cross-references

## Homepage + Quickstarts (M2)
- Add scenario entry cards to homepage with hand-drawn design
- 5 quickstart pages: Claude Code, GitHub Copilot (with copy mode recommendation),
  Codex, Multiple Tools, Dev Containers, Playground

## Blog + Changelog (M3)
- Enable Docusaurus blog plugin with authors.yml
- 5 blog posts: 5-min tutorial, managing 50+ skills, skillshare vs vercel/skills
  comparison, team sharing patterns, write your first skill
- Static /changelog page from CHANGELOG.md

## Recipes + Philosophy (M4)
- 5 recipe pages: CI/CD validation, enterprise skills, project setup,
  cross-machine sync, team onboarding
- 3 philosophy pages: why-local-first, security-first, sync-modes-explained

## Content Polish
- Cross-validate all content against CLI source (19 inaccuracies fixed)
- Lowercase "skillshare" throughout (avoid brand conflict with Skillshare Inc.)
- Add registry.yaml to file structure and Key Paths docs
- Highlight multi-platform git support (GitHub, GitLab, Bitbucket, Gitea,
  Azure DevOps, AtomGit, Codeberg)
- Standardize brew install command
- Add AsciinemaPlayer component (cast recordings pending)
2026-02-26 22:27:23 +08:00
Willie a8f04320ea docs: add required token scopes per platform for auth errors
- environment-variables.md: add token creation steps and required scopes
  for GitLab (read_repository + write_repository) and Bitbucket
  (repository access token vs app password)
- common-errors.md: add token permissions quick-reference table
- CLI auth hint: append docs URL for detailed scope info
2026-02-22 08:08:35 +08:00
Willie 83d13f6e10 feat: add platform-specific token setup hints for auth errors
- CLI auth hint now shows PowerShell syntax on Windows, export on Unix
- Docs: add Windows PowerShell examples for GITLAB_TOKEN, BITBUCKET_TOKEN,
  SKILLSHARE_GIT_TOKEN in environment-variables.md
- Docs: rewrite auth error section in common-errors.md with token env var
  options, Windows syntax, and GitLab token type warning
2026-02-22 08:08:35 +08:00
Willie 692d87c4cc fix: use .md extension in relative doc links to prevent 404s
Relative links like `./sync` resolve differently depending on
whether the page URL has a trailing slash. Adding `.md` lets
Docusaurus resolve them at build time, fixing broken links when
navigating via the navbar.
2026-02-16 16:16:18 +08:00
Willie 403aafb254 feat: unify project target names with global names, add aliases for backward compat
Project targets now use the same short names as global targets (e.g.,
"claude" instead of "claude-code"). Old project_name values are preserved
as aliases so existing configs continue to work.

- Add Aliases field to targetSpec (deprecated, remove once safe)
- Update 11 targets in targets.yaml: project_name = global_name
- LookupProjectTarget falls back to alias lookup
- Fix 3 callers that bypassed LookupProjectTarget
- Extend MatchesTargetName and KnownTargetNames with alias support
- Add TestLookupProjectTarget_Alias
- Update all integration tests, docs, CLI help, and FAQ
2026-02-16 00:08:59 +08:00
Willie 5b437c343a docs: add project config examples to collision detection sections
Each collision detection section now shows both global and project
config filter syntax, with a cross-reference link to the full
target filters documentation.
2026-02-14 18:59:04 +08:00
Willie 43d12b11c1 feat: per-target collision detection with filter-aware reporting
Collision checks previously ran on all skills before target filters,
producing false positive warnings when users route same-named skills
to different targets via include/exclude. Now collision detection
runs per-target after filtering, downgrading to info when filters
correctly isolate duplicates.

- Add CheckNameCollisionsForTargets() to internal/sync
- Replace collision blocks in sync.go and sync_project.go
- Show human-readable filter summary per merge target
- Add unit tests (5 cases) and integration test
- Update docs with new two-tier collision output examples
2026-02-14 18:35:21 +08:00
Willie ac58c5e71e docs: reorganize sidebar, add project migration, fix metadata format
- Guides: split 10 flat items into 3 sub-categories (Skills, Sharing, Advanced)
- Workflows: move Troubleshooting Workflow into Troubleshooting category
- Migration: add project mode sections (committed skills, global→project, team options)
- Configuration: add audit section, project config format, custom audit rules
- Navbar: add Guides and Targets quick links
- Fix .skillshare.yaml → .skillshare-meta.json across all docs (wrong filename/format)
- Bump font sizes site-wide for readability (base 16→17px, components proportional)
2026-02-13 14:21:36 +08:00
Willie 3830543309 feat: auto-commit and auto-pull on init, improve git UX
Init now creates an initial commit (including .gitignore) so that
push/pull work immediately after setup. When a remote is configured,
init fetches and auto-pulls existing skills from the remote.

- Always create initial commit in doGitInit (fixes stale untracked
  .gitignore blocking pull)
- Add ensureGitIdentity: set repo-local fallback when git user.name
  is not configured, with hint to set global config
- Add tryPullAfterRemoteSetup: fetch remote after adding origin,
  auto-pull if remote has content and local is empty
- Add hintGitRemoteError: context-aware hints for SSH, URL, and
  network errors in push/pull
- Show Pro tip only when built-in skill is installed
- Sandbox: add --bare mode (skip auto-init), --volumes for down
  (full reset), and sandbox-reset / sandbox:reset targets
- Docs: update init flow diagram, cross-machine-sync guide,
  push/pull prerequisites, getting-started, troubleshooting
2026-02-13 14:21:36 +08:00
Willie 4d17ff5d57 feat: add security audit — scan engine, CLI, install hooks, web UI, and docs
Scan skills for prompt injection, data exfiltration, credential access,
destructive commands, obfuscation, and suspicious URLs. CRITICAL findings
block installation by default; HIGH/MEDIUM shown as warnings.

- Scan engine: internal/audit with regex-based pattern matching
- CLI: `skillshare audit [name]` with per-skill progress and summary
- Install hooks: auto-scan after copy, block on CRITICAL unless --force
- Web UI: AuditPage with run/rescan, InstallForm shows ConfirmDialog
  for audit blocks (force-retry) and warning details
- ConfirmDialog: add `wide` prop, hide cancel when cancelText is empty
- Reduced false positives: rm -rf only flags root/glob, skip localhost
  URLs, exclude `fetch` as English word, hidden-unicode downgraded to HIGH
- README: add audit section, update screenshots, unify image sizes,
  add audit to Why/Comparison/Daily Commands
- Docs: audit command page, install security scanning section, FAQ,
  common errors, daily workflow, sidebar, landing page, intro
- Blog specs: add audit sections to Dev.to and Medium drafts
2026-02-10 01:53:55 +08:00
Willie 092fb14f8a feat: add web dashboard with embedded React SPA (skillshare ui)
Single-binary web UI for visual skill management — React 19 + Vite
frontend embedded via go:embed, Go net/http REST API backend (30+
endpoints). Includes dashboard, skills browser, targets, sync, collect,
search, install, config editor, backup/restore, and git sync pages.

Also adds Bitbucket/GitLab URL parsing for install, git operations
library, skill version checking, CI frontend build steps, Docker
sandbox support, and website docs for the ui command.
2026-02-08 05:08:30 +08:00
Willie 9cef926a68 docs(website): refactor docs 2026-02-01 22:52:11 +08:00