Skip to content

fix: init.sh fallback for Hermes consumers + skills:install alias#25

Merged
htafolla merged 1 commit intomasterfrom
fix/init-sh-fallback-and-skills-alias
Mar 30, 2026
Merged

fix: init.sh fallback for Hermes consumers + skills:install alias#25
htafolla merged 1 commit intomasterfrom
fix/init-sh-fallback-and-skills-alias

Conversation

@htafolla
Copy link
Copy Markdown
Owner

Problem

  1. init.sh not showing version banner: postinstall skips .opencode/ copy entirely when ~/.hermes is detected. The OpenCode plugin then silently skips init.sh because it only checks the project-local path.

  2. skills:install not recognized: only skill:install (singular) was registered. Users naturally type the plural.

Fix

  1. Plugin config hook now falls back to node_modules/strray-ai/.opencode/init.sh when the project-local copy doesn't exist.
  2. Added .alias('skills:install') to the commander registration.

Tested

Packed the branch as .tgz, installed in clean /tmp/strray-pr-test/:

  • npx strray-ai skills:install --help → works (shows both names)
  • npx strray-ai skill:install <github-url> → gh repo clone fires, installs 31 skills
  • npx strray-ai health/validate/version → all pass
  • Verified project-local init.sh is absent (Hermes skip), package init.sh exists, fallback resolves correctly

…nstall

- Plugin falls back to node_modules/strray-ai/.opencode/init.sh when
  postinstall skips .opencode/ copy (Hermes consumers)
- Reorder cloneRepo: try gh repo clone FIRST when authenticated,
  then tarball fallback, then git clone. Previously gh was buried
  after tarball and never fired (tarball always succeeds for public repos)
- Applied to both src/ and .opencode/plugin/ (the shipped artifact)

Tested: npm pack → clean install → gh fires first, init.sh fallback works
@htafolla htafolla force-pushed the fix/init-sh-fallback-and-skills-alias branch from 976ec1b to 01b4ab3 Compare March 30, 2026 21:26
@htafolla htafolla merged commit 6e2121b into master Mar 30, 2026
10 of 11 checks passed
@htafolla htafolla deleted the fix/init-sh-fallback-and-skills-alias branch March 30, 2026 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant