Skip to content

armgit / ruflo

Public Imported from GitHub
0

🌊 The original agent harness. Deploy intelligent multi-player swarms, coordinate autonomous workflows, and build conversational AI systems. Features adaptive memory, self-learning intelligence, federation, vector RAG integration, and native Claude Code / Codex / Hermes and many more Integrated

fix(console): pin the skills CLI the Skills page runs

martinvladfa03159b4817
diff --git a/plugins/ruflo-console/hooks/data/skills.ts b/plugins/ruflo-console/hooks/data/skills.ts
index 1791e90aac..809f9ab5b1 100644
--- a/plugins/ruflo-console/hooks/data/skills.ts
+++ b/plugins/ruflo-console/hooks/data/skills.ts
@@ -8,8 +8,14 @@ import type { Outcome } from '../state'
import { jsonAfter } from './cli'
import { plain, recordOf, stringOf } from './parse'
-/** `npx -y skills`: downloads the CLI on first use, so every run here reaches the network. */
-export const SKILLS = ['npx', '-y', 'skills'] as const
+/**
+ * The skills CLI release every action runs, pinned like the AI page's Codex (`PINNED_CODEX`): `npx -y skills` would
+ * fetch and execute whatever `latest` is at that moment, with the person's permissions and their agents' skill folders.
+ * Raise it deliberately after reading the new release.
+ */
+export const PINNED_SKILLS = '1.7.2'
+/** `npx -y skills@<pin>`: downloads that CLI on first use, so every run here reaches the network. */
+export const SKILLS = ['npx', '-y', `skills@${PINNED_SKILLS}`] as const
export type Scope = 'project' | 'global'
diff --git a/plugins/ruflo-console/hooks/views/skills-more.ts b/plugins/ruflo-console/hooks/views/skills-more.ts
index 1af2852acc..cbb1bd499c 100644
--- a/plugins/ruflo-console/hooks/views/skills-more.ts
+++ b/plugins/ruflo-console/hooks/views/skills-more.ts
@@ -46,7 +46,7 @@ export function previewRows(ctx: Ctx): RenderElement[] {
rows.push(rule(ctx, 'Preview', previewing !== null ? `reading ${clip(previewing, 40)}…` : preview === null ? '' : `${preview.kind === 'installed' ? 'local read' : 'add --list · nothing installed'} · ${ago(preview.atMs, nowMs)}`))
- if (using !== null) rows.push(text(ctx, ` ▸ fetching ${using} for the AI terminal (npx -y skills use)…`, { color: THEME.warn }))
+ if (using !== null) rows.push(text(ctx, ` â–¸ fetching ${using} for the AI terminal (npx -y [email protected] use)…`, { color: THEME.warn }))
if (preview === null) return rows
rows.push(
diff --git a/plugins/ruflo-console/hooks/views/skills.ts b/plugins/ruflo-console/hooks/views/skills.ts
index 0861fb09cb..c12b882268 100644
--- a/plugins/ruflo-console/hooks/views/skills.ts
+++ b/plugins/ruflo-console/hooks/views/skills.ts
@@ -32,7 +32,7 @@ function installedRows(ctx: Ctx): RenderElement[] {
for (const [scope, error] of Object.entries(skills.listErrors)) rows.push(text(ctx, ` ${scope} list unreadable: ${error}`, { color: THEME.warn }))
if (skills.installed === null) {
- rows.push(text(ctx, skills.isListing ? ' asking npx -y skills ls --json (project) and ls -g --json (global)… the first run downloads the CLI' : ' not listed yet: r lists them (npx -y skills ls --json)', { dimColor: true }))
+ rows.push(text(ctx, skills.isListing ? ' asking npx -y [email protected] ls --json (project) and ls -g --json (global)… the first run downloads the CLI' : ' not listed yet: r lists them (npx -y [email protected] ls --json)', { dimColor: true }))
} else if (installed.length === 0 && Object.keys(skills.listErrors).length === 0) {
rows.push(text(ctx, ' no skills in this project or globally: search below and â–¸ add one', { dimColor: true }))
}
diff --git a/plugins/ruflo-console/tests/palette.test.ts b/plugins/ruflo-console/tests/palette.test.ts
index 6ba84daf60..447b84bb7a 100644
--- a/plugins/ruflo-console/tests/palette.test.ts
+++ b/plugins/ruflo-console/tests/palette.test.ts
@@ -197,20 +197,20 @@ describe('palette and /ruflo', () => {
test('skills headless: /ruflo run skills-find answers with what skills.sh found; skills-update asks first', { options: { boot: false } }, async ($, on) => {
const world = worldOf(on, RUFLO_FILES)
- world.respond = argv => (argv[2] !== 'skills' ? cliAnswer(argv) : { exitCode: 0, stdout: argv[3] === 'find' ? FIND_OUT : argv[3] === 'ls' ? '[]' : 'done\n', stderr: '' })
+ world.respond = argv => (argv[2] !== '[email protected]' ? cliAnswer(argv) : { exitCode: 0, stdout: argv[3] === 'find' ? FIND_OUT : argv[3] === 'ls' ? '[]' : 'done\n', stderr: '' })
mock.clock(on)
await $.session.start({ ...SESSION, isInteractive: false })
const found = (await $.command.run(command('run skills-find react'))).text ?? ''
expect(found).toMatch(/^skills find "react": 4 found\n {2}mattpocock\/skills@tdd · 1M installs/)
- expect(runsOf(world.runs, 'find')).toEqual([['npx', '-y', 'skills', 'find', 'react']])
+ expect(runsOf(world.runs, 'find')).toEqual([['npx', '-y', '[email protected]', 'find', 'react']])
expect((await $.command.run(command('run skills-update'))).text).toContain('Asked: update every project skill. Confirm with /ruflo yes (or y in the pane), cancel with /ruflo no.')
expect(runsOf(world.runs, 'update')).toEqual([])
// A skills change runs its own command and reports into the skills view, so the confirm answers before it ends.
expect((await $.command.run(command('yes'))).text).toBe('Ran.')
await $.command.run(command('status'))
- expect(runsOf(world.runs, 'update')).toEqual([['npx', '-y', 'skills', 'update', '-p', '-y']])
+ expect(runsOf(world.runs, 'update')).toEqual([['npx', '-y', '[email protected]', 'update', '-p', '-y']])
})
test('/ruflo help, an unknown word, and the hints when ruflo-mods or ruflo-swarm are not loaded', { options: { boot: false } }, async ($, on) => {
diff --git a/plugins/ruflo-console/tests/skills-lab.spec.ts b/plugins/ruflo-console/tests/skills-lab.spec.ts
index 634d214663..82e6eb9a6f 100644
--- a/plugins/ruflo-console/tests/skills-lab.spec.ts
+++ b/plugins/ruflo-console/tests/skills-lab.spec.ts
@@ -20,18 +20,18 @@ const GOOD = ['---', 'name: my-skill', 'description: Does one thing well. Use wh
describe('argv for the new actions', () => {
it('add names only known agents, after the scope and before -y; use, --list, update-all, restore and sync are fixed', () => {
- expect(addArgv('o/r@s', 'project', ['codex', 'claude-code'])).toEqual(['npx', '-y', 'skills', 'add', 'o/r@s', '--agent', 'claude-code', 'codex', '-y'])
- expect(addArgv('o/r@s', 'global', ['cursor', '-y', '*', 'evil;rm'])).toEqual(['npx', '-y', 'skills', 'add', 'o/r@s', '-g', '--agent', 'cursor', '-y'])
- expect(addArgv('o/r@s', 'global', [])).toEqual(['npx', '-y', 'skills', 'add', 'o/r@s', '-g', '-y'])
+ expect(addArgv('o/r@s', 'project', ['codex', 'claude-code'])).toEqual(['npx', '-y', '[email protected]', 'add', 'o/r@s', '--agent', 'claude-code', 'codex', '-y'])
+ expect(addArgv('o/r@s', 'global', ['cursor', '-y', '*', 'evil;rm'])).toEqual(['npx', '-y', '[email protected]', 'add', 'o/r@s', '-g', '--agent', 'cursor', '-y'])
+ expect(addArgv('o/r@s', 'global', [])).toEqual(['npx', '-y', '[email protected]', 'add', 'o/r@s', '-g', '-y'])
expect(agentsOf(['codex', 'codex', 'nope'])).toEqual(['codex'])
- expect(useArgv('o/r@s')).toEqual(['npx', '-y', 'skills', 'use', 'o/r@s'])
- expect(listRepoArgv('o/r@s')).toEqual(['npx', '-y', 'skills', 'add', 'o/r@s', '--list'])
+ expect(useArgv('o/r@s')).toEqual(['npx', '-y', '[email protected]', 'use', 'o/r@s'])
+ expect(listRepoArgv('o/r@s')).toEqual(['npx', '-y', '[email protected]', 'add', 'o/r@s', '--list'])
expect(listRepoArgv('o/r@s')).not.toContain('--json')
- expect(updateAllArgv('project')).toEqual(['npx', '-y', 'skills', 'update', '-p', '-y'])
- expect(updateAllArgv('global')).toEqual(['npx', '-y', 'skills', 'update', '-g', '-y'])
- expect(restoreArgv()).toEqual(['npx', '-y', 'skills', 'experimental_install'])
- expect(syncArgv()).toEqual(['npx', '-y', 'skills', 'experimental_sync', '-y'])
- expect(syncArgv(['claude-code'])).toEqual(['npx', '-y', 'skills', 'experimental_sync', '--agent', 'claude-code', '-y'])
+ expect(updateAllArgv('project')).toEqual(['npx', '-y', '[email protected]', 'update', '-p', '-y'])
+ expect(updateAllArgv('global')).toEqual(['npx', '-y', '[email protected]', 'update', '-g', '-y'])
+ expect(restoreArgv()).toEqual(['npx', '-y', '[email protected]', 'experimental_install'])
+ expect(syncArgv()).toEqual(['npx', '-y', '[email protected]', 'experimental_sync', '-y'])
+ expect(syncArgv(['claude-code'])).toEqual(['npx', '-y', '[email protected]', 'experimental_sync', '--agent', 'claude-code', '-y'])
})
})
@@ -194,7 +194,7 @@ describe('the new skills actions', () => {
act.use({ id: 'vercel-labs/agent-skills@vercel-react-best-practices' })
await until(() => loaded.length > 0)
- expect(runs).toEqual([['npx', '-y', 'skills', 'use', 'vercel-labs/agent-skills@vercel-react-best-practices']])
+ expect(runs).toEqual([['npx', '-y', '[email protected]', 'use', 'vercel-labs/agent-skills@vercel-react-best-practices']])
expect(state.pending).toBeNull()
expect(loaded[0]).toContain('<SKILL.md>')
expect(state.outcome).toMatchObject({ ok: true })
@@ -209,7 +209,7 @@ describe('the new skills actions', () => {
act.previewFound({ id: 'vercel-labs/agent-skills@vercel-react-best-practices' })
await until(() => state.skills.preview !== null)
- expect(runs).toEqual([['npx', '-y', 'skills', 'add', 'vercel-labs/agent-skills@vercel-react-best-practices', '--list']])
+ expect(runs).toEqual([['npx', '-y', '[email protected]', 'add', 'vercel-labs/agent-skills@vercel-react-best-practices', '--list']])
expect(state.skills.preview?.lines[0]).toBe('â–¸ vercel-react-best-practices')
act.previewInstalled({ name: 'my-skill', path: '/home/dev/.agents/skills/my-skill', scope: 'global', agents: [] })
@@ -227,24 +227,24 @@ describe('the new skills actions', () => {
const { state, runner, runs, act } = fake(argv => ({ exitCode: 0, stdout: argv[3] === 'ls' ? '[]' : 'ok', stderr: '' }))
act.updateAll()
- expect(state.pending).toMatchObject({ shows: 'npx -y skills update -p -y', note: expect.stringMatching(/network/) })
+ expect(state.pending).toMatchObject({ shows: 'npx -y [email protected] update -p -y', note: expect.stringMatching(/network/) })
expect(runs).toEqual([])
await runner.confirm()
await until(() => state.skills.busy === null && runs.length >= 3)
- expect(runs[0]).toEqual(['npx', '-y', 'skills', 'update', '-p', '-y'])
+ expect(runs[0]).toEqual(['npx', '-y', '[email protected]', 'update', '-p', '-y'])
act.restore()
- expect(state.pending).toMatchObject({ shows: 'npx -y skills experimental_install', note: expect.stringMatching(/experimental · network/) })
+ expect(state.pending).toMatchObject({ shows: 'npx -y [email protected] experimental_install', note: expect.stringMatching(/experimental · network/) })
runner.cancel()
act.scope('global')
act.toggleAgent('claude-code')
act.toggleAgent('not-an-agent')
act.sync()
- expect(state.pending?.shows).toBe('npx -y skills experimental_sync --agent claude-code -y')
+ expect(state.pending?.shows).toBe('npx -y [email protected] experimental_sync --agent claude-code -y')
runner.cancel()
act.updateAll()
- expect(state.pending?.shows).toBe('npx -y skills update -g -y')
+ expect(state.pending?.shows).toBe('npx -y [email protected] update -g -y')
runner.cancel()
expect(runs).toHaveLength(3)
})
@@ -262,7 +262,7 @@ describe('the new skills actions', () => {
expect(sortedFound(state.skills.found, state.skills.sort).map(skill => skill.id)).toEqual(['a/b@high', 'a/b@low'])
act.sortBy()
expect(sortedFound(state.skills.found, state.skills.sort).map(skill => skill.id)).toEqual(['a/b@low', 'a/b@high'])
- expect(addSpec(state, host, { id: 'o/r@s' }, 'global')?.shows).toBe('npx -y skills add o/r@s -g --agent claude-code -y')
+ expect(addSpec(state, host, { id: 'o/r@s' }, 'global')?.shows).toBe('npx -y [email protected] add o/r@s -g --agent claude-code -y')
expect(addSpec(state, host, { id: 'o/r@s' }, 'global')?.label).toBe('add skill o/r@s globally for claude-code')
})
@@ -324,11 +324,11 @@ describe('the new skills actions', () => {
expect(runner.runById('skills-find', 'react')).toBe(true)
await runner.settled()
- expect(runs).toEqual([['npx', '-y', 'skills', 'find', 'react']])
+ expect(runs).toEqual([['npx', '-y', '[email protected]', 'find', 'react']])
expect(skillsAnswer(state, 'skills-find', askedAtMs)).toMatch(/^skills find "react": 4 found\n {2}mattpocock\/skills@tdd · 1M installs/)
expect(runner.runById('skills-update', '')).toBe(true)
- expect(state.pending?.shows).toBe('npx -y skills update -p -y')
+ expect(state.pending?.shows).toBe('npx -y [email protected] update -p -y')
runner.cancel()
expect(runner.runById('skills-find', '-rf')).toBe(true)
expect(runs).toHaveLength(1)
diff --git a/plugins/ruflo-console/tests/skills-secure.test.ts b/plugins/ruflo-console/tests/skills-secure.test.ts
index b0c0549815..22563ce17d 100644
--- a/plugins/ruflo-console/tests/skills-secure.test.ts
+++ b/plugins/ruflo-console/tests/skills-secure.test.ts
@@ -25,9 +25,9 @@ import { drawn } from './fixtures/views'
describe('skills, security and performance', () => {
test('skills: installed, search and create sections; opening lists, nothing else runs until asked and confirmed', { options: { boot: false } }, async ($, on) => {
const world = worldOf(on, RUFLO_FILES)
- const skillRuns = () => world.runs.filter(argv => argv[2] === 'skills').map(argv => argv.slice(3).join(' '))
+ const skillRuns = () => world.runs.filter(argv => argv[2] === '[email protected]').map(argv => argv.slice(3).join(' '))
- world.respond = argv => (argv[2] !== 'skills' ? cliAnswer(argv) : argv[3] === 'ls' ? { exitCode: 0, stdout: argv.includes('-g') ? LS_GLOBAL : '[]', stderr: '' } : argv[3] === 'find' ? { exitCode: 0, stdout: FIND_OUT, stderr: '' } : { exitCode: 0, stdout: 'done\n', stderr: '' })
+ world.respond = argv => (argv[2] !== '[email protected]' ? cliAnswer(argv) : argv[3] === 'ls' ? { exitCode: 0, stdout: argv.includes('-g') ? LS_GLOBAL : '[]', stderr: '' } : argv[3] === 'find' ? { exitCode: 0, stdout: FIND_OUT, stderr: '' } : { exitCode: 0, stdout: 'done\n', stderr: '' })
mock.clock(on)
await $.session.start(SESSION)
@@ -58,7 +58,7 @@ describe('skills, security and performance', () => {
// The scope is chosen once, above the lists; â–¸ add then installs there.
await pane.press({ key: 'sk-scope-global' })
await pane.press({ key: 'sk-add-0' })
- expect(textOf(await pane.drawn())).toContain('runs: npx -y skills add mattpocock/skills@tdd -g -y')
+ expect(textOf(await pane.drawn())).toContain('runs: npx -y [email protected] add mattpocock/skills@tdd -g -y')
expect(skillRuns().some(line => line.startsWith('add'))).toBe(false)
await pane.press({ key: 'confirm' })
@@ -142,10 +142,10 @@ describe('skills, security and performance', () => {
test('skills: use, preview, targets, maintain and scan; reads run on a click, every change asks with its argv and cost', { options: { boot: false } }, async ($, on) => {
const files = { ...RUFLO_FILES, 'package.json': JSON.stringify({ dependencies: { react: '19' } }), '.claude/agents/coder.md': 'Use the tdd skill.' }
const world = worldOf(on, files)
- const skillRuns = () => world.runs.filter(argv => argv[2] === 'skills').map(argv => argv.slice(3).join(' '))
+ const skillRuns = () => world.runs.filter(argv => argv[2] === '[email protected]').map(argv => argv.slice(3).join(' '))
const answer = (argv: readonly string[]) => (argv[3] === 'ls' ? (argv.includes('-g') ? LS_GLOBAL : '[]') : argv[3] === 'find' ? FIND_OUT : argv[3] === 'use' ? USE_OUT : argv.includes('--list') ? LIST_OUT : 'done\n')
- world.respond = argv => (argv[2] !== 'skills' ? cliAnswer(argv) : { exitCode: 0, stdout: answer(argv), stderr: '' })
+ world.respond = argv => (argv[2] !== '[email protected]' ? cliAnswer(argv) : { exitCode: 0, stdout: answer(argv), stderr: '' })
mock.clock(on)
await $.session.start(SESSION)
@@ -164,7 +164,7 @@ describe('skills, security and performance', () => {
await pane.press({ key: 'sk-update-all' })
const asked = textOf(await pane.drawn())
- expect(asked).toContain('runs: npx -y skills update -p -y')
+ expect(asked).toContain('runs: npx -y [email protected] update -p -y')
expect(asked).toMatch(/network: fetches each skill/)
expect(skillRuns()).toEqual(['ls --json', 'ls -g --json'])
await pane.press({ key: 'confirm' })
@@ -173,7 +173,7 @@ describe('skills, security and performance', () => {
// â–¸ restore asks, and is not run when cancelled.
await pane.press({ key: 'sk-restore' })
- expect(textOf(await pane.drawn())).toContain('runs: npx -y skills experimental_install')
+ expect(textOf(await pane.drawn())).toContain('runs: npx -y [email protected] experimental_install')
await pane.press({ key: 'cancel' })
expect(skillRuns()).not.toContain('experimental_install')
diff --git a/plugins/ruflo-console/tests/skills.spec.ts b/plugins/ruflo-console/tests/skills.spec.ts
index 09fed65876..49db7d5244 100644
--- a/plugins/ruflo-console/tests/skills.spec.ts
+++ b/plugins/ruflo-console/tests/skills.spec.ts
@@ -5,7 +5,7 @@
*/
import { describe, expect, it } from 'vitest'
-import { addArgv, findArgv, initArgv, listArgv, newNameOf, parseFind, parseInstalled, removeArgv, skillIdOf, skillNameOf, typedOf, updateArgv } from '../hooks/data/skills'
+import { addArgv, findArgv, initArgv, listArgv, PINNED_SKILLS, useArgv, newNameOf, parseFind, parseInstalled, removeArgv, skillIdOf, skillNameOf, typedOf, updateArgv } from '../hooks/data/skills'
import type { Host } from '../hooks/host'
import { createRunner } from '../hooks/runner'
import { addSpec, editPrompt, findSkills, initSpec, listSkills, removeSpec, skillActions } from '../hooks/skills'
@@ -42,20 +42,27 @@ describe('reading the skills CLI', () => {
})
describe('argv and validation', () => {
- it('every action is a fixed npx -y skills argv, its scope named', () => {
- expect(listArgv('project')).toEqual(['npx', '-y', 'skills', 'ls', '--json'])
- expect(listArgv('global')).toEqual(['npx', '-y', 'skills', 'ls', '-g', '--json'])
- expect(addArgv('vercel-labs/skills@find-skills', 'project')).toEqual(['npx', '-y', 'skills', 'add', 'vercel-labs/skills@find-skills', '-y'])
- expect(addArgv('vercel-labs/skills@find-skills', 'global')).toEqual(['npx', '-y', 'skills', 'add', 'vercel-labs/skills@find-skills', '-g', '-y'])
- expect(removeArgv('tdd', 'global')).toEqual(['npx', '-y', 'skills', 'remove', 'tdd', '-g', '-y'])
- expect(updateArgv('tdd', 'project')).toEqual(['npx', '-y', 'skills', 'update', 'tdd', '-p', '-y'])
- expect(updateArgv('tdd', 'global')).toEqual(['npx', '-y', 'skills', 'update', 'tdd', '-g', '-y'])
- expect(initArgv('my-skill')).toEqual(['npx', '-y', 'skills', 'init', 'my-skill'])
+ it('every action is a fixed npx -y [email protected] argv, its scope named', () => {
+ expect(listArgv('project')).toEqual(['npx', '-y', '[email protected]', 'ls', '--json'])
+ expect(listArgv('global')).toEqual(['npx', '-y', '[email protected]', 'ls', '-g', '--json'])
+ expect(addArgv('vercel-labs/skills@find-skills', 'project')).toEqual(['npx', '-y', '[email protected]', 'add', 'vercel-labs/skills@find-skills', '-y'])
+ expect(addArgv('vercel-labs/skills@find-skills', 'global')).toEqual(['npx', '-y', '[email protected]', 'add', 'vercel-labs/skills@find-skills', '-g', '-y'])
+ expect(removeArgv('tdd', 'global')).toEqual(['npx', '-y', '[email protected]', 'remove', 'tdd', '-g', '-y'])
+ expect(updateArgv('tdd', 'project')).toEqual(['npx', '-y', '[email protected]', 'update', 'tdd', '-p', '-y'])
+ expect(updateArgv('tdd', 'global')).toEqual(['npx', '-y', '[email protected]', 'update', 'tdd', '-g', '-y'])
+ expect(initArgv('my-skill')).toEqual(['npx', '-y', '[email protected]', 'init', 'my-skill'])
+ })
+
+ it('every action runs the pinned skills release, never whatever npm `latest` is', () => {
+ expect(PINNED_SKILLS).toMatch(/^\d+\.\d+\.\d+$/)
+ for (const argv of [listArgv('project'), listArgv('global'), addArgv('o/r@s', 'project'), removeArgv('tdd', 'project'), updateArgv('tdd', 'global'), initArgv('my-skill'), useArgv('o/r@s'), findArgv('react')]) {
+ expect(argv?.slice(0, 3)).toEqual(['npx', '-y', `skills@${PINNED_SKILLS}`])
+ }
})
it('search: the text is one argv element; owner:<name> becomes --owner; flags, odd characters and long text are refused', () => {
- expect(findArgv(' react hooks ')).toEqual(['npx', '-y', 'skills', 'find', 'react hooks'])
- expect(findArgv('owner:vercel-labs deploy')).toEqual(['npx', '-y', 'skills', 'find', 'deploy', '--owner', 'vercel-labs'])
+ expect(findArgv(' react hooks ')).toEqual(['npx', '-y', '[email protected]', 'find', 'react hooks'])
+ expect(findArgv('owner:vercel-labs deploy')).toEqual(['npx', '-y', '[email protected]', 'find', 'deploy', '--owner', 'vercel-labs'])
expect(findArgv('-g')).toBeNull()
expect(findArgv('--owner x')).toBeNull()
expect(findArgv('react; rm -rf ~')).toBeNull()
@@ -135,7 +142,7 @@ describe('the skills actions', () => {
expect(runs).toEqual([])
expect(findSkills(state, host, 'react')).toBeNull()
await settle()
- expect(runs).toEqual([['npx', '-y', 'skills', 'find', 'react']])
+ expect(runs).toEqual([['npx', '-y', '[email protected]', 'find', 'react']])
expect(state.skills.found?.length).toBe(4)
})
@@ -150,14 +157,14 @@ describe('the skills actions', () => {
const spec = addSpec(state, host, { id: 'mattpocock/skills@TDD' }, 'project')
runner.ask(spec, '')
- expect(state.pending?.shows).toBe('npx -y skills add mattpocock/skills@TDD -y')
+ expect(state.pending?.shows).toBe('npx -y [email protected] add mattpocock/skills@TDD -y')
expect(runs).toEqual([])
await runner.confirm()
for (let i = 0; i < 20 && state.skills.busy !== null; i++) await settle()
await settle()
- expect(runs[0]).toEqual(['npx', '-y', 'skills', 'add', 'mattpocock/skills@TDD', '-y'])
+ expect(runs[0]).toEqual(['npx', '-y', '[email protected]', 'add', 'mattpocock/skills@TDD', '-y'])
expect(runs.slice(1).map(argv => argv[3])).toEqual(['ls', 'ls'])
expect(state.outcome).toMatchObject({ label: 'add skill mattpocock/skills@TDD to this project', ok: true, verified: 'yes' })
expect(state.skills.last?.label).toBe(state.outcome?.label)
@@ -176,12 +183,12 @@ describe('the skills actions', () => {
expect(state.outcome?.detail).toMatch(/no slash/)
act.create('my-skill')
- expect(state.pending?.shows).toBe('npx -y skills init my-skill')
+ expect(state.pending?.shows).toBe('npx -y [email protected] init my-skill')
expect(runs).toEqual([])
act.create('my-skill')
for (let i = 0; i < 20 && (state.skills.busy !== null || runs.length === 0); i++) await settle()
- expect(runs[0]).toEqual(['npx', '-y', 'skills', 'init', 'my-skill'])
+ expect(runs[0]).toEqual(['npx', '-y', '[email protected]', 'init', 'my-skill'])
const skill = { name: 'tdd', path: '/home/dev/.agents/skills/tdd', scope: 'global' as const, agents: [] }