Allows serving the UI under a URL prefix (e.g., skillshare ui --base-path /app).
The flag value is passed through to the server constructors and used for
browser URL construction. Falls back to SKILLSHARE_UI_BASE_PATH env var
when the flag is not provided.
Add normalizeBasePath + wrapBasePath to Server so the UI and API can be
served under a URL prefix (e.g. /app). StripPrefix wraps outside
withConfigAutoReload; bare-path requests redirect to path + "/".
Dev mode (no uiDistDir) prints a warning and skips wrapping.
Includes HTTP routing tests for prefix routing, 404 without prefix,
bare-path redirect, multi-level paths, and empty basePath passthrough.
- Remove dead nil check in ignorePayload() (repoFiles already initialized)
- Replace manual map merge loops with maps.Copy in 3 handler sites
- Deduplicate fmt.Sprintf + ui.Success in doctor checkSkillignore
- Extract extractIgnoreSources() helper in SyncPage to DRY two identical
state-setting blocks
Separate the environment checks (config, source, skillignore, git)
from the skill validation checks (integrity, targets) with a blank
line for better readability.
The collision report dumped all 14000+ duplicate names on a single
line, making the sync output unreadable. Show the first 5 names
with "... and N more" so users can see examples without the flood.
The doctor handler shells out to the CLI binary. In global mode it
did not pass -g, so the subprocess auto-detected project mode when
the server's cwd contained .skillshare/config.yaml. This caused
the doctor to check the project source instead of the global source.
Extract printIgnoredSkills helper that shows whether ignores come from
root-level, repo-level, or both .skillignore files. Helps users
understand why skills are excluded when they haven't configured the
root .skillignore.
Switch DiscoverSourceSkills → DiscoverSourceSkillsWithStats at both
global and project sync entry points. Thread IgnoreStats through to
text output (dim-styled list) and JSON output (ignored_count +
ignored_skills fields).
Surface .skillignore visibility in the status command so users can
see active patterns and how many skills are being ignored without
needing to run doctor.
Text output shows an indented line under Source when .skillignore
exists; JSON output adds a skillignore object inside source with
active flag, file paths, patterns, and ignored skill details.
Add checkInfo status constant for informational (non-pass/warn/error)
doctor checks. Info checks count toward total but are tracked separately
in the summary.
Add checkSkillignore to doctor: reports .skillignore state as either
info (no .skillignore found) or pass (active with pattern/ignored counts
and details). Switches discovery from DiscoverSourceSkills to
DiscoverSourceSkillsWithStats to collect .skillignore statistics in the
same walk.
Skills without .skillshare-meta.json are local/manual — silently skip
instead of warning. Only warn when meta exists but file_hashes is
missing (old installs). List affected skill names in the warning.
- Extract 14-line duplicated JSON output block from cmdDoctorGlobal and
cmdDoctorProject into shared finalizeDoctorJSON() function
- Define checkPass/checkWarning/checkError constants replacing 42 string
literals across all addCheck() call sites
- Add TODO comment in server handler noting intent to move check logic
into internal/ package
Add `--json` flag to `skillshare doctor` that outputs structured JSON with
per-check results, summary counts, and version info. Errors produce exit 1,
warnings exit 0. Uses suppressUIToDevnull() to silence text output in JSON mode.
partialInitRepair was falling through to the interactive prompt path,
which returns empty in non-TTY (CI). Add explicit branch that auto-selects
all detected CLI directories, restoring the pre-v0.17.3 behavior.
Fixes TestListProject_PartialInit_RepairsMissingConfig.
Without this fix, running `init --subdir` in a directory with
.skillshare/config.yaml would auto-detect project mode and fail
with "unknown option: --subdir" because the project parser doesn't
support it. Adding --subdir to hasGlobalOnlyInitFlags() ensures
correct routing to global mode.
Also adds 5 integration tests covering --subdir end-to-end:
config path, list discovery, sync symlinks, mode routing, dry-run.
Previously, `init` silently defaulted source to ~/.config/skillshare/skills/
with no way for users to discover customization without reading docs. Now
interactive mode asks whether to customize the source path (Y/N gate + text
input), with tilde expansion and filepath.Abs normalization. The success
message also hints at --source and config path for future changes.
- promptSourcePath() follows same Y/N pattern as useSourceSubdir()
- TTY guard ensures non-interactive (piped stdin, --source flag) is unaffected
- Integration test verifies success message contains source hint
- Updated init.md flowchart, --source option note, and first-sync.md steps
Enable teams to use one project as a shared skills repo where each
developer manages their own targets independently.
- Add `--config local` flag to `init -p` that gitignores config.yaml
- Auto-detect shared repo on clone via .gitignore check (no flag needed)
- Fix partialInitRepair to run interactive prompt instead of auto-select
- Export GitignoreContains, add UpdateGitIgnoreFiles for file-mode entries
- Refactor gitignore helpers to share addGitIgnoreEntries private helper
- Add 5 integration tests covering all new flows
- Add recipe docs page, update init reference, changelogs, release notes
Project mode uninstall moves skills to .skillshare/trash/, but this
directory was not gitignored — soft-deleted skills could be accidentally
committed.
- ensureProjectGitignore now adds both logs/ and trash/ via a single
UpdateGitIgnoreBatch call (replaces two separate UpdateGitIgnore calls)
- uninstall_project.go calls ensureProjectGitignore for backward compat,
patching projects created before this fix on next uninstall run
- Remove unused configPath field from model
- Replace capitalizeFilterType with existing capitalize() helper
- Remove unused width/height params from renderFilterEditPanel
- Only clear detailScroll/lastActionMsg on selection change (match extras)
- Extract shared buildTargetTUIItems() to deduplicate loadTargets/reloadTargetItems
- Change Spacing() from 1 to 0 for compact list display
- Add help footer with full keybinding hints (match extras)
- Move filterBar above detail in vertical layout (match extras)
- Add "\n" prefix to detail panel in split view (match extras)
- Use rightWidth-1 for wrapAndScroll (match extras)
- Use "\n\n" after split body (match extras)
- Esc clears filter text (match extras)
- "/" returns textinput.Blink for cursor animation
- Add loading guard for key/mouse events
- Add ResetSelected after filter
- Use tc.Title for detail name (not inline style)
- Store lastActionMsg as plain text, render at display time
- Add renderTargetActionMsg with ✓/✗ color logic
- ctrl+d/u scroll step 5→8 (match extras/skill)
- Add width guard in delegate Render
The --subdir flag was parsed and functional but missing from the
help text printed by `skillshare init --help`.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
dirSize() was called synchronously for every backup version during list
population and on each cursor move, blocking the entire TUI event loop.
- Add ListBackupVersionsLite() that skips dirSize (TotalSize = -1)
- Compute size asynchronously via tea.Cmd, cache in versionSizeCache
- Replace redundant ListBackupVersions() in renderTargetDetail() with
direct os.ReadDir() on the latest backup directory
- Cap per-skill I/O (readSkillDescription + listSkillFiles) to 20 items
in both renderTargetDetail() and renderVersionDetail()
Replace list.DefaultDelegate + configureDelegate() with a new
prefixItemDelegate that renders the "▌" prefix bar consistently
across all 11 TUI list views (log, trash, search, install prompt,
checklist, restore, audit rules, diff).
- Add prefixItemDelegate (1-line) and renderPrefixRowWithDesc (2-line)
- Remove configureDelegate(), NormalTitle/Desc, SelectedTitle/Desc styles
- Remove hardcoded " " indent from restore item Title() methods
- Fix AuditPage overflow handling with overflow prop and !overflow-clip
Replace vertical stack layout with horizontal split panel matching
list_tui and log_tui patterns. Reuses renderHorizontalSplit,
wrapAndScroll, and appendScrollInfo from tui_helpers.go.
Key changes:
- Add termHeight tracking and syncTrashListSize() for responsive layout
- Add detailScroll with Ctrl+d/u and mouse wheel support on right panel
- Split View() into viewTrashSplit() (≥80 cols) and viewTrashVertical()
- Render detail panel with bold header, metadata rows, path truncation
- Add renderTrashSummaryFooter with item count and total size
- Remove cachedDetailStr/cachedDetailIdx in favor of direct rendering
- Enable tea.WithMouseCellMotion() for mouse wheel scrolling