@harness-lab/cli 0.2.1 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/README.md +15 -5
  2. package/assets/workshop-bundle/SKILL.md +306 -0
  3. package/assets/workshop-bundle/bundle-manifest.json +232 -0
  4. package/assets/workshop-bundle/content/challenge-cards/.gitkeep +0 -0
  5. package/assets/workshop-bundle/content/challenge-cards/deck.md +38 -0
  6. package/assets/workshop-bundle/content/challenge-cards/locales/en/deck.md +38 -0
  7. package/assets/workshop-bundle/content/challenge-cards/print-spec.md +28 -0
  8. package/assets/workshop-bundle/content/czech-editorial-review-checklist.md +88 -0
  9. package/assets/workshop-bundle/content/facilitation/.gitkeep +0 -0
  10. package/assets/workshop-bundle/content/facilitation/codex-setup-verification.md +54 -0
  11. package/assets/workshop-bundle/content/facilitation/master-guide.md +131 -0
  12. package/assets/workshop-bundle/content/project-briefs/.gitkeep +0 -0
  13. package/assets/workshop-bundle/content/project-briefs/code-review-helper.md +31 -0
  14. package/assets/workshop-bundle/content/project-briefs/devtoolbox-cli.md +31 -0
  15. package/assets/workshop-bundle/content/project-briefs/doc-generator.md +31 -0
  16. package/assets/workshop-bundle/content/project-briefs/locales/en/code-review-helper.md +31 -0
  17. package/assets/workshop-bundle/content/project-briefs/locales/en/devtoolbox-cli.md +31 -0
  18. package/assets/workshop-bundle/content/project-briefs/locales/en/doc-generator.md +31 -0
  19. package/assets/workshop-bundle/content/project-briefs/locales/en/metrics-dashboard.md +31 -0
  20. package/assets/workshop-bundle/content/project-briefs/locales/en/standup-bot.md +31 -0
  21. package/assets/workshop-bundle/content/project-briefs/metrics-dashboard.md +31 -0
  22. package/assets/workshop-bundle/content/project-briefs/standup-bot.md +31 -0
  23. package/assets/workshop-bundle/content/style-examples.md +127 -0
  24. package/assets/workshop-bundle/content/style-guide.md +108 -0
  25. package/assets/workshop-bundle/content/talks/.gitkeep +0 -0
  26. package/assets/workshop-bundle/content/talks/codex-demo-script.md +43 -0
  27. package/assets/workshop-bundle/content/talks/context-is-king.md +42 -0
  28. package/assets/workshop-bundle/docs/harness-cli-foundation.md +143 -0
  29. package/assets/workshop-bundle/docs/learner-reference-gallery.md +82 -0
  30. package/assets/workshop-bundle/docs/learner-resource-kit.md +126 -0
  31. package/assets/workshop-bundle/docs/locales/en/learner-reference-gallery.md +82 -0
  32. package/assets/workshop-bundle/docs/locales/en/learner-resource-kit.md +126 -0
  33. package/assets/workshop-bundle/docs/workshop-event-context-contract.md +123 -0
  34. package/assets/workshop-bundle/materials/locales/en/participant-resource-kit.md +72 -0
  35. package/assets/workshop-bundle/materials/participant-resource-kit.md +72 -0
  36. package/assets/workshop-bundle/workshop-blueprint/README.md +55 -0
  37. package/assets/workshop-bundle/workshop-blueprint/agenda.json +70 -0
  38. package/assets/workshop-bundle/workshop-blueprint/control-surfaces.md +101 -0
  39. package/assets/workshop-bundle/workshop-blueprint/day-structure.md +129 -0
  40. package/assets/workshop-bundle/workshop-blueprint/edit-boundaries.md +64 -0
  41. package/assets/workshop-bundle/workshop-blueprint/operator-guide.md +74 -0
  42. package/assets/workshop-bundle/workshop-blueprint/teaching-spine.md +134 -0
  43. package/assets/workshop-bundle/workshop-skill/.gitkeep +0 -0
  44. package/assets/workshop-bundle/workshop-skill/analyze-checklist.md +21 -0
  45. package/assets/workshop-bundle/workshop-skill/closing-skill.md +30 -0
  46. package/assets/workshop-bundle/workshop-skill/commands.md +44 -0
  47. package/assets/workshop-bundle/workshop-skill/facilitator.md +426 -0
  48. package/assets/workshop-bundle/workshop-skill/follow-up-package.md +35 -0
  49. package/assets/workshop-bundle/workshop-skill/install.md +58 -0
  50. package/assets/workshop-bundle/workshop-skill/locales/en/commands.md +44 -0
  51. package/assets/workshop-bundle/workshop-skill/locales/en/follow-up-package.md +35 -0
  52. package/assets/workshop-bundle/workshop-skill/locales/en/recap.md +22 -0
  53. package/assets/workshop-bundle/workshop-skill/locales/en/reference.md +80 -0
  54. package/assets/workshop-bundle/workshop-skill/locales/en/setup.md +84 -0
  55. package/assets/workshop-bundle/workshop-skill/recap.md +22 -0
  56. package/assets/workshop-bundle/workshop-skill/reference.md +80 -0
  57. package/assets/workshop-bundle/workshop-skill/setup.md +84 -0
  58. package/assets/workshop-bundle/workshop-skill/template-agents.md +35 -0
  59. package/package.json +8 -3
  60. package/src/run-cli.js +16 -9
  61. package/src/skill-install.js +98 -57
  62. package/src/workshop-bundle.js +236 -0
@@ -0,0 +1,80 @@
1
+ # Workshop Reference
2
+
3
+ ## 4 working defaults for today
4
+
5
+ - `Map before motion` - first make the repo a place people can navigate
6
+ - `If it is not in the repo, it does not exist` - important agreements, rules, and next steps belong in files
7
+ - `Verification is the trust boundary` - more autonomy requires stronger evidence
8
+ - `Handoff is a continuous constraint` - the next team should find the first safe move without your explanation
9
+
10
+ ## 4 elements of a good task
11
+
12
+ - `Goal` - what exactly the agent should create or change
13
+ - `Context` - which files, decisions, and surrounding facts matter for the task
14
+ - `Constraints` - the rules, standards, and solution boundaries
15
+ - `Done When` - how you will know the work is actually finished
16
+
17
+ ## Fast handoff checklist
18
+
19
+ - Does `AGENTS.md` exist?
20
+ - Is `AGENTS.md` a short map rather than an overgrown dump?
21
+ - Are there build and test commands in the repo that another team can run?
22
+ - Is it clear what already works, what is in progress, and what is still only an idea?
23
+ - Is there a plan, runbook, or another document that helps the next team understand the intent?
24
+ - Can you find what was actually verified?
25
+ - Can a new team find the first safe move within a few minutes?
26
+
27
+ ## Recommended commands
28
+
29
+ - Workshop skill in Codex: `$workshop ...`
30
+ - Workshop skill in pi: `/skill:workshop`, then ask for `reference`, `setup`, `brief`, or another workshop action
31
+ - If you do not know what the skill can do: `Codex: $workshop commands`
32
+ - The workshop skill is the guaranteed default. Workflow skills and external toolkits are recommended accelerators, not mandatory bootstrap.
33
+ - Workflow skills like `$brainstorm`, `$plan`, `$work`, `$test-writer`, `$review`, and `$compound` are described Codex-first in this workshop. In pi, treat them as optional parts of your own setup rather than the guaranteed default.
34
+ - `Codex: $workshop reference` at the start of the day or after you lose orientation
35
+ - `Codex: $workshop brief` when you need to re-anchor the task
36
+ - `Codex: $workshop resources` when you want the participant kit and learner kit without searching the repo
37
+ - `Codex: $workshop gallery` when you want more public docs, repos, and optional toolkits
38
+ - `Codex: $workshop follow-up` when you are deciding what to keep after the workshop
39
+ - `Codex: $brainstorm` when the scope is still unclear
40
+ - `Codex: $plan` before larger implementation
41
+ - `Codex: $work` once you have a plan and want to keep implementation in one line
42
+ - `Codex: $test-writer` or your own RED test before implementation when you need to keep the agent inside real boundaries
43
+ - `Codex: $review` after a larger slice of work
44
+ - `Codex: $compound` when a learning, fix, or workflow rule is worth preserving as a durable repo-native artifact
45
+ - `Codex: $workshop` for orientation during the day
46
+ - `Codex: $workshop template` when the repo is missing baseline context
47
+ - `Codex: $workshop analyze` before handoff or after rotation when you want to expose blind spots in the repo quickly
48
+
49
+ ## Recommended participant loop
50
+
51
+ - `workshop` for orientation and the next safe move
52
+ - `brainstorm` or directly `plan` when the scope is already clear
53
+ - `work` against one verifiable goal
54
+ - `review` before you trust a change
55
+ - `compound` or a short runbook when something is worth preserving
56
+ - ongoing cleanup work: move build and test commands, constraints, and handoff notes from chat into the repo
57
+
58
+ ## Tests as the trust boundary
59
+
60
+ - The more work the agent does independently, the less “I skimmed it quickly” is enough.
61
+ - If you let the agent write without tests, you often just accelerate unverified complexity.
62
+ - A RED test, tracer bullet, or simple end-to-end check is often the fastest way to tell the agent what must actually be true.
63
+
64
+ ## Safe UI workflow
65
+
66
+ - The default pattern is: `agent exploration -> Playwright regression -> human review`.
67
+ - Let the agent inspect the UI, screenshots, and console quickly in an isolated local environment.
68
+ - Once you find an important flow, turn it into a repeatable browser test.
69
+ - Then have a human review the change. Tests protect against regression, but they do not decide meaning or trade-offs for you.
70
+ - “Let the model drive my normal signed-in browser” is not the default recommendation. That belongs only in a sandboxed, intentionally constrained environment.
71
+
72
+ ## Quick reminder
73
+
74
+ A good prompt is not enough. If the work should survive handoff, the context must live in the repo and verification must stay traceable.
75
+
76
+ ## Where to go after the workshop
77
+
78
+ - Official docs, the OpenAI Harness Engineering article, and verified public skill repos are collected in [`docs/learner-reference-gallery.md`](../../../docs/learner-reference-gallery.md).
79
+ - If you already use another workflow pack or toolkit, treat it as an extension on top of this foundation, not as a replacement for `AGENTS.md`, verification, and repo-native handoff.
80
+ - If you do not want to search the repo, use `workshop resources`, `workshop gallery`, or `workshop follow-up` directly.
@@ -0,0 +1,84 @@
1
+ # Workshop Setup
2
+
3
+ ## Goal
4
+
5
+ By 10:30, you need one working path into Codex or pi. Not a perfect setup. A working path.
6
+
7
+ The first goal after setup is not a feature. It is orientation:
8
+
9
+ - open the repo
10
+ - load the workshop guidance
11
+ - create a short `AGENTS.md`
12
+ - name the first verifiable step
13
+
14
+ The guaranteed default for today is the `workshop` skill. Additional workflow skills or external toolkits are optional accelerators, not a requirement for participation.
15
+
16
+ ## Fastest choice
17
+
18
+ - terminal-first, hackable multi-model setup: `pi`
19
+ - macOS / Linux: `Codex CLI`
20
+ - Windows or macOS: `Codex App`
21
+ - if you get blocked: web fallback or pair with someone whose setup already works
22
+
23
+ ## pi
24
+
25
+ 1. Install `pi`:
26
+
27
+ ```bash
28
+ npm install -g @mariozechner/pi-coding-agent
29
+ ```
30
+
31
+ 2. Sign in to the provider or account you want to use.
32
+ 3. Open the repository.
33
+ 4. Run `pi`.
34
+ 5. Load the workshop skill with `/skill:workshop` and ask for `setup`, `reference`, or `brief`.
35
+
36
+ ## Codex CLI
37
+
38
+ 1. Confirm that you have access to your Codex account.
39
+ 2. Install the CLI using your organization's setup flow.
40
+ 3. Sign in.
41
+ 4. Open the repository.
42
+ 5. Send the first meaningful prompt and confirm that you get a response.
43
+
44
+ ## Codex App
45
+
46
+ 1. Install the app.
47
+ 2. Sign in with the same account.
48
+ 3. Open the workshop repo or your team project.
49
+ 4. Send the first prompt.
50
+ 5. Confirm that you can continue without another blocker.
51
+
52
+ ## If something does not work
53
+
54
+ - Do not spend 20 minutes debugging setup alone.
55
+ - After 7 minutes of being blocked, switch to App, web fallback, or pairing.
56
+ - If authentication fails, continue with someone at your table and come back to your own setup later.
57
+ - If you are unsure about the next step, use `$workshop setup` in Codex. In pi, load `/skill:workshop` and ask for setup help. Or call a facilitator.
58
+
59
+ ## First 15 minutes after setup
60
+
61
+ 1. Open workshop reference:
62
+ - Codex: `$workshop reference`
63
+ - pi: `/skill:workshop`, then ask for `reference`
64
+ - if you want a fast overview of the skill surface: `Codex: $workshop commands`
65
+ 2. Open the brief:
66
+ - Codex: `$workshop brief`
67
+ - pi: `/skill:workshop`, then ask for `brief`
68
+ 3. Add a short `AGENTS.md`:
69
+ - Codex: `$workshop template`
70
+ 4. Name the first safe move:
71
+ - ideally through `plan`, or `brainstorm` if the scope is still unclear
72
+ 5. Add one executable check:
73
+ - a RED test, tracer bullet, or at least a clear review or checklist step
74
+ 6. If you want materials for later too:
75
+ - `Codex: $workshop resources`
76
+ - `Codex: $workshop gallery`
77
+ - `Codex: $workshop follow-up`
78
+
79
+ ## Done when
80
+
81
+ - You can open the repo.
82
+ - You can send a prompt.
83
+ - You have one working path for using an agent during the workshop.
84
+ - You know the first safe move in the repo after setup.
@@ -0,0 +1,22 @@
1
+ # Workshop Recap
2
+
3
+ ## Co si odnést
4
+
5
+ - Kontext není kosmetika. Je to pracovní systém.
6
+ - `AGENTS.md`, skills a runbooky nejsou doplněk navíc. Jsou to nástroje, díky kterým tým drží směr.
7
+ - Dobrý handoff poznáte podle toho, že nový tým začne pracovat bez ústního dovysvětlování.
8
+
9
+ ## Zkuste tento týden
10
+
11
+ - Přidejte `AGENTS.md` do jednoho reálného projektu.
12
+ - Doplňte build/test příkazy a sekci `Done When`.
13
+ - Jedno trvalé pravidlo přesuňte z promptu do repa.
14
+ - Po větší změně zkuste udělat krátký runbook pro dalšího člověka.
15
+
16
+ ## Váš závazek
17
+
18
+ Vraťte se ke sticky note z části `A teď?` a převeďte ji na první konkrétní commit, pull request nebo task v repu.
19
+
20
+ ## Až si nebudete jistí
21
+
22
+ Začněte jednoduše: napište, co chcete udělat, kde je kontext, jaká jsou omezení a podle čeho poznáte hotovo.
@@ -0,0 +1,80 @@
1
+ # Workshop Reference
2
+
3
+ ## 4 pracovní výchozí body pro dnešek
4
+
5
+ - `Mapa před pohybem` — nejdřív udělejte z repa místo, kde se dá orientovat
6
+ - `Co není v repu, neexistuje` — důležité dohody, pravidla a další kroky patří do souborů
7
+ - `Ověření je hranice důvěry` — s větší autonomií musí růst i kvalita evidence
8
+ - `Handoff je průběžná podmínka práce` — další tým má najít první bezpečný krok bez vašeho výkladu
9
+
10
+ ## 4 prvky dobrého zadání
11
+
12
+ - `Cíl` — co má agent konkrétně vytvořit nebo změnit
13
+ - `Kontext` — které soubory, rozhodnutí a souvislosti jsou pro úkol důležité
14
+ - `Omezení` — pravidla, standardy a hranice řešení
15
+ - `Hotovo když` — podle čeho poznáte, že je práce opravdu dokončená
16
+
17
+ ## Rychlý checklist pro handoff
18
+
19
+ - Existuje `AGENTS.md`?
20
+ - Je `AGENTS.md` krátká mapa, ne přerostlý dump?
21
+ - Jsou v repu build/test příkazy, které umí spustit i další tým?
22
+ - Je jasné, co už funguje, co je rozpracované a co je jen nápad?
23
+ - Je v repu plan, runbook nebo jiný dokument, ze kterého další tým pochopí záměr?
24
+ - Je dohledatelné, co bylo skutečně ověřeno?
25
+ - Najde nový tým během pár minut první bezpečný krok?
26
+
27
+ ## Doporučené příkazy
28
+
29
+ - Workshop skill v Codexu: `$workshop ...`
30
+ - Workshop skill v pi: `/skill:workshop`, potom si řekněte o `reference`, `setup`, `brief` nebo jinou workshop akci
31
+ - Když nevíte, co skill umí: `Codex: $workshop commands`
32
+ - Workshop skill je garantovaný výchozí nástroj. Workflow skills a externí toolkity jsou doporučené akcelerátory, ne povinný bootstrap.
33
+ - Workflow skills jako `$brainstorm`, `$plan`, `$work`, `$test-writer`, `$review` a `$compound` jsou v tomto workshopu popsané hlavně pro Codex. V pi je berte jako volitelnou součást vlastního setupu, ne jako garantovaný výchozí stav.
34
+ - `Codex: $workshop reference` na začátku dne nebo po ztrátě orientace
35
+ - `Codex: $workshop brief` když potřebujete znovu ukotvit zadání
36
+ - `Codex: $workshop resources` když chcete účastnický kit a learner kit bez hledání v repu
37
+ - `Codex: $workshop gallery` když chcete další veřejné docs, repozitáře a volitelné toolkity
38
+ - `Codex: $workshop follow-up` když řešíte, co si odnést po workshopu
39
+ - `Codex: $brainstorm` když ještě není jasné, co je nejrozumnější scope nebo slice
40
+ - `Codex: $plan` před větší implementací
41
+ - `Codex: $work` když už máte plan a chcete držet implementaci v jedné linii
42
+ - `Codex: $test-writer` nebo vlastní RED test před implementací, když potřebujete držet agenta v mezích
43
+ - `Codex: $review` po větším kusu práce
44
+ - `Codex: $compound` když chcete převést nové zjištění, fix nebo workflow pravidlo do trvalého artefaktu v repu
45
+ - `Codex: $workshop` pro orientaci během dne
46
+ - `Codex: $workshop template` když repu chybí základní kontext
47
+ - `Codex: $workshop analyze` před handoffem nebo po rotaci, když chcete rychle odhalit slepá místa v repu
48
+
49
+ ## Doporučený pracovní rytmus
50
+
51
+ - `workshop` pro orientaci a další bezpečný krok
52
+ - `brainstorm` nebo rovnou `plan`, když už je scope zřejmý
53
+ - `work` proti jednomu ověřitelnému cíli
54
+ - `review` před tím, než změně uvěříte
55
+ - `compound` nebo krátký runbook, když něco stojí za zachování
56
+ - průběžný úklid: build/test příkazy, omezení a handoff poznámky přesouvejte z chatu do repa
57
+
58
+ ## Testy jako hranice důvěry
59
+
60
+ - Čím víc práce dělá agent samostatně, tím méně stačí „já jsem to rychle projel očima“.
61
+ - Když necháte agenta psát bez testů, často jen urychlíte vznik neověřené složitosti.
62
+ - RED test, tracer bullet nebo jednoduché e2e ověření je často nejrychlejší způsob, jak agentovi říct, co přesně má být pravda.
63
+
64
+ ## Bezpečný UI workflow
65
+
66
+ - Výchozí pattern je: `agent exploration -> Playwright regression -> human review`.
67
+ - Nechte agenta rychle projít UI, screenshoty a konzoli v izolovaném lokálním prostředí.
68
+ - Jakmile najdete důležitý flow, převeďte ho do opakovatelného browser testu.
69
+ - Nakonec změnu projděte člověkem. Testy chrání proti regresi, ale neřeší automaticky smysl a trade-offy.
70
+ - „Nech model řídit můj běžný přihlášený browser“ není výchozí doporučení. To patří jen do sandboxovaného a záměrně omezeného prostředí.
71
+
72
+ ## Rychlá připomínka
73
+
74
+ Dobrý prompt nestačí. Když má práce přežít handoff, musí být kontext uložený v repu a ověření musí být dohledatelné.
75
+
76
+ ## Kam dál po workshopu
77
+
78
+ - Oficiální docs, OpenAI článek o Harness Engineering a ověřené veřejné skill repozitáře najdete v [`docs/learner-reference-gallery.md`](../docs/learner-reference-gallery.md).
79
+ - Když už používáte další workflow pack nebo toolkit, berte ho jako rozšíření nad tímto základem, ne jako náhradu za `AGENTS.md`, ověřování a handoff opřený o repo.
80
+ - Když nechcete hledat v repu, použijte přímo `workshop resources`, `workshop gallery` nebo `workshop follow-up`.
@@ -0,0 +1,84 @@
1
+ # Workshop Setup
2
+
3
+ ## Cíl
4
+
5
+ Do 10:30 potřebujete jednu funkční cestu do Codexu nebo pi. Ne perfektní setup. Funkční cestu.
6
+
7
+ První cíl po setupu není feature. Je to orientace:
8
+
9
+ - otevřít repo
10
+ - načíst workshopové pokyny
11
+ - vytvořit krátké `AGENTS.md`
12
+ - pojmenovat první ověřitelný krok
13
+
14
+ Garantovaný výchozí nástroj pro dnešek je `workshop` skill. Další workflow skills nebo externí toolkity jsou volitelné zrychlení, ne podmínka účasti.
15
+
16
+ ## Nejrychlejší volba
17
+
18
+ - terminálový, hackovatelný multi-model setup: `pi`
19
+ - macOS / Linux: `Codex CLI`
20
+ - Windows nebo macOS: `Codex App`
21
+ - Když se zaseknete: web fallback nebo pairing s někým, komu už setup běží
22
+
23
+ ## pi
24
+
25
+ 1. Nainstalujte `pi`:
26
+
27
+ ```bash
28
+ npm install -g @mariozechner/pi-coding-agent
29
+ ```
30
+
31
+ 2. Přihlaste provider nebo účet, který chcete používat.
32
+ 3. Otevřete repozitář.
33
+ 4. Spusťte `pi`.
34
+ 5. Načtěte workshop skill přes `/skill:workshop` a řekněte si o `setup`, `reference` nebo `brief`.
35
+
36
+ ## Codex CLI
37
+
38
+ 1. Ověřte, že máte přístup ke svému Codex účtu.
39
+ 2. Nainstalujte CLI podle interního setup flow vaší organizace.
40
+ 3. Přihlaste se.
41
+ 4. Otevřete repozitář.
42
+ 5. Pošlete první smysluplný prompt a ověřte, že dostáváte odpověď.
43
+
44
+ ## Codex App
45
+
46
+ 1. Nainstalujte aplikaci.
47
+ 2. Přihlaste se stejným účtem.
48
+ 3. Otevřete workshop repo nebo týmový projekt.
49
+ 4. Pošlete první prompt.
50
+ 5. Ověřte, že můžete pokračovat bez další blokace.
51
+
52
+ ## Když něco nefunguje
53
+
54
+ - Neztrácejte 20 minut sólo debugováním setupu.
55
+ - Po 7 minutách blokace přepněte na App, web fallback nebo pairing.
56
+ - Když nefunguje autentizace, pokračujte s někým od stolu a vraťte se k vlastnímu setupu později.
57
+ - Když si nejste jistí dalším krokem, použijte v Codexu `$workshop setup`. V pi načtěte `/skill:workshop` a řekněte si o setup pomoc. Nebo si zavolejte facilitátora.
58
+
59
+ ## Prvních 15 minut po setupu
60
+
61
+ 1. Spusťte `workshop` reference:
62
+ - Codex: `$workshop reference`
63
+ - pi: `/skill:workshop`, potom si řekněte o `reference`
64
+ - když chcete rychlý přehled toho, co skill umí: `Codex: $workshop commands`
65
+ 2. Otevřete brief:
66
+ - Codex: `$workshop brief`
67
+ - pi: `/skill:workshop`, potom si řekněte o `brief`
68
+ 3. Doplňte krátké `AGENTS.md`:
69
+ - Codex: `$workshop template`
70
+ 4. Pojmenujte první bezpečný krok:
71
+ - ideálně přes `plan`, případně `brainstorm`, když scope ještě není jasný
72
+ 5. Přidejte jeden executable check:
73
+ - RED test, tracer bullet nebo aspoň jasný review/checklist krok
74
+ 6. Když chcete materiály i po workshopu:
75
+ - `Codex: $workshop resources`
76
+ - `Codex: $workshop gallery`
77
+ - `Codex: $workshop follow-up`
78
+
79
+ ## Hotovo když
80
+
81
+ - Umíte otevřít repo.
82
+ - Umíte poslat prompt.
83
+ - Máte jednu funkční cestu, jak během workshopu pracovat s agentem.
84
+ - Víte, jaký je první bezpečný krok v repu po setupu.
@@ -0,0 +1,35 @@
1
+ # AGENTS.md Starter
2
+
3
+ Použijte to jako krátkou mapu repa. Ne jako encyklopedii. Když detail patří jinam, odkažte na konkrétní soubor místo kopírování dlouhého textu.
4
+
5
+ Nejdůležitější pravidlo:
6
+ - napište, kam má agent sáhnout jako první
7
+ - napište, co je zdroj pravdy
8
+ - napište, jak se práce ověří
9
+ - když se text nafukuje, přidejte navazující dokument a odkažte na něj
10
+
11
+ ## Goal
12
+
13
+ Popiš, co má agent v tomto repozitáři vytvořit nebo udržovat.
14
+
15
+ ## Context
16
+
17
+ - Klíčové soubory a složky
18
+ - Rozhodnutí, která už padla
19
+ - Systémy nebo integrace, na které se navazuje
20
+ - Kam má agent sáhnout jako první
21
+ - Které docs nebo runbooky jsou zdroj pravdy
22
+
23
+ ## Constraints
24
+
25
+ - Build/test/lint příkazy
26
+ - Jazykové, architektonické a bezpečnostní standardy
27
+ - Co agent nesmí dělat bez explicitního souhlasu
28
+ - Public/private nebo auth boundary, pokud existuje
29
+
30
+ ## Done When
31
+
32
+ - Jak poznáme, že je práce hotová
33
+ - Jaké ověření musí proběhnout
34
+ - Jak má vypadat handoff pro dalšího člověka nebo agenta
35
+ - Jaký bude další bezpečný krok, pokud práce zůstane rozdělaná
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@harness-lab/cli",
3
- "version": "0.2.1",
3
+ "version": "0.2.3",
4
4
  "description": "Participant-facing Harness Lab CLI for facilitator auth and workshop operations",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",
@@ -20,12 +20,13 @@
20
20
  "ai-agents"
21
21
  ],
22
22
  "engines": {
23
- "node": ">=24"
23
+ "node": "22.x"
24
24
  },
25
25
  "publishConfig": {
26
26
  "access": "public"
27
27
  },
28
28
  "files": [
29
+ "assets",
29
30
  "bin",
30
31
  "src",
31
32
  "README.md"
@@ -37,6 +38,10 @@
37
38
  "chalk": "^5.6.2"
38
39
  },
39
40
  "scripts": {
40
- "test": "node --test"
41
+ "preverify:workshop-bundle": "node ./scripts/sync-workshop-bundle.mjs --with-repo-bundle",
42
+ "prepack": "node ./scripts/sync-workshop-bundle.mjs",
43
+ "sync:workshop-bundle": "node ./scripts/sync-workshop-bundle.mjs --with-repo-bundle",
44
+ "verify:workshop-bundle": "node ./scripts/verify-workshop-bundle.mjs",
45
+ "test": "npm run verify:workshop-bundle && node --test"
41
46
  }
42
47
  }
package/src/run-cli.js CHANGED
@@ -173,7 +173,7 @@ function printUsage(io, ui) {
173
173
  "harness auth login [--auth device|basic|neon] [--dashboard-url URL] [--username USER] [--email EMAIL] [--password PASS] [--no-open]",
174
174
  "harness auth logout",
175
175
  "harness auth status",
176
- "harness skill install [--force]",
176
+ "harness skill install [--target PATH] [--force]",
177
177
  "harness workshop status",
178
178
  "harness workshop archive [--notes TEXT]",
179
179
  "harness workshop create-instance [<instance-id>] [--template-id ID] [--event-title TEXT] [--city CITY]",
@@ -190,23 +190,30 @@ function printVersion(io) {
190
190
 
191
191
  async function handleSkillInstall(io, ui, deps, flags) {
192
192
  try {
193
- const result = await installWorkshopSkill(deps.cwd ?? process.cwd(), { force: flags.force === true });
193
+ const result = await installWorkshopSkill(deps.cwd ?? process.cwd(), {
194
+ force: flags.force === true,
195
+ target: readStringFlag(flags, "target"),
196
+ });
194
197
  ui.heading("Workshop Skill");
195
- if (result.mode === "already_bundled") {
196
- ui.status("ok", "Harness Lab workshop skill is already bundled in this repo.");
198
+ if (result.mode === "already_current") {
199
+ ui.status("ok", "Harness Lab workshop skill is already current at the target path.");
200
+ } else if (result.mode === "refreshed") {
201
+ ui.status("ok", "Refreshed the installed Harness Lab workshop skill bundle.");
197
202
  } else {
198
203
  ui.status("ok", "Installed the Harness Lab workshop skill bundle.");
199
204
  }
205
+ ui.keyValue("Target", result.targetRoot);
200
206
  ui.keyValue("Location", result.installPath);
201
207
  ui.keyValue("Discovery", ".agents/skills");
208
+ ui.keyValue("Bundle source", result.sourceMode === "packaged_bundle" ? "packaged portable bundle" : "source checkout fallback");
202
209
  ui.blank();
203
210
  ui.section("Next steps");
204
211
  ui.numberedList([
205
- "Open Codex or pi in this repo.",
206
- "Start with the workshop reference card.",
207
- "Codex: `$workshop reference`.",
208
- "pi: `/skill:workshop`, then ask for the workshop reference card.",
209
- "Need setup help? Codex: `$workshop setup`. pi: `/skill:workshop`, then ask for setup help.",
212
+ "Open Codex or pi in the target repo.",
213
+ "Start with the workshop command menu.",
214
+ "Codex: `$workshop commands`.",
215
+ "pi: `/skill:workshop`, then ask for the workshop commands.",
216
+ "Next: `$workshop reference`, `$workshop brief`, and `$workshop resources`.",
210
217
  ]);
211
218
  return 0;
212
219
  } catch (error) {
@@ -1,5 +1,16 @@
1
1
  import fs from "node:fs/promises";
2
2
  import path from "node:path";
3
+ import {
4
+ createWorkshopBundleManifestFromDirectory,
5
+ createWorkshopBundleManifestFromSource,
6
+ createWorkshopBundleFromSource,
7
+ getInstalledSkillPath,
8
+ getPackagedWorkshopBundlePath,
9
+ getRepoWorkshopSourceRoot,
10
+ pathExists,
11
+ readWorkshopBundleManifest,
12
+ WORKSHOP_SKILL_NAME,
13
+ } from "./workshop-bundle.js";
3
14
 
4
15
  export class SkillInstallError extends Error {
5
16
  constructor(message, options = {}) {
@@ -9,94 +20,124 @@ export class SkillInstallError extends Error {
9
20
  }
10
21
  }
11
22
 
12
- const SKILL_NAME = "harness-lab-workshop";
23
+ async function resolveBundleSource() {
24
+ const packagedBundlePath = getPackagedWorkshopBundlePath();
25
+ if (await pathExists(path.join(packagedBundlePath, "SKILL.md"))) {
26
+ return {
27
+ mode: "packaged_bundle",
28
+ sourcePath: packagedBundlePath,
29
+ sourceRoot: packagedBundlePath,
30
+ };
31
+ }
13
32
 
14
- async function pathExists(targetPath) {
15
- try {
16
- await fs.access(targetPath);
17
- return true;
18
- } catch {
19
- return false;
33
+ const repoSourceRoot = getRepoWorkshopSourceRoot();
34
+ if (await pathExists(path.join(repoSourceRoot, "workshop-skill", "SKILL.md"))) {
35
+ return {
36
+ mode: "repo_source",
37
+ sourcePath: repoSourceRoot,
38
+ sourceRoot: repoSourceRoot,
39
+ };
20
40
  }
41
+
42
+ return null;
21
43
  }
22
44
 
23
- export async function findHarnessLabRepoRoot(startDir) {
24
- let currentDir = path.resolve(startDir);
45
+ async function ensureDirectory(targetPath) {
46
+ await fs.mkdir(targetPath, { recursive: true });
47
+ const stat = await fs.stat(targetPath);
48
+ if (!stat.isDirectory()) {
49
+ throw new SkillInstallError(`Install target is not a directory: ${targetPath}`, {
50
+ code: "invalid_target",
51
+ });
52
+ }
53
+ }
25
54
 
26
- while (true) {
27
- if (await pathExists(path.join(currentDir, "workshop-skill", "SKILL.md"))) {
28
- return currentDir;
29
- }
55
+ async function hasInstalledSkill(targetRoot) {
56
+ return pathExists(path.join(getInstalledSkillPath(targetRoot), "SKILL.md"));
57
+ }
30
58
 
31
- const parentDir = path.dirname(currentDir);
32
- if (parentDir === currentDir) {
33
- return null;
59
+ async function getSourceBundleManifest(resolvedBundle) {
60
+ if (resolvedBundle.mode === "packaged_bundle") {
61
+ const manifest = await readWorkshopBundleManifest(resolvedBundle.sourcePath);
62
+ if (manifest) {
63
+ return manifest;
34
64
  }
35
65
 
36
- currentDir = parentDir;
66
+ return createWorkshopBundleManifestFromDirectory(resolvedBundle.sourcePath);
37
67
  }
38
- }
39
68
 
40
- export function getInstalledSkillPath(repoRoot) {
41
- return path.join(repoRoot, ".agents", "skills", SKILL_NAME);
69
+ return createWorkshopBundleManifestFromSource(resolvedBundle.sourceRoot);
42
70
  }
43
71
 
44
- async function hasBundledRepoSkill(repoRoot) {
45
- return pathExists(path.join(getInstalledSkillPath(repoRoot), "SKILL.md"));
72
+ async function installFromResolvedBundle(resolvedBundle, installPath) {
73
+ if (resolvedBundle.mode === "packaged_bundle") {
74
+ await fs.cp(resolvedBundle.sourcePath, installPath, { recursive: true });
75
+ return;
76
+ }
77
+
78
+ await createWorkshopBundleFromSource(resolvedBundle.sourceRoot, installPath);
46
79
  }
47
80
 
48
81
  export async function installWorkshopSkill(startDir, options = {}) {
49
- const repoRoot = await findHarnessLabRepoRoot(startDir);
50
- if (!repoRoot) {
82
+ const resolvedBundle = await resolveBundleSource();
83
+ if (!resolvedBundle) {
51
84
  throw new SkillInstallError(
52
- "Harness CLI could not find `workshop-skill/SKILL.md`. Run this command inside a Harness Lab repo checkout.",
53
- { code: "repo_not_found" },
85
+ "Harness CLI could not find a portable workshop bundle. Reinstall `@harness-lab/cli` or run from a Harness Lab source checkout.",
86
+ { code: "bundle_not_found" },
54
87
  );
55
88
  }
56
89
 
57
- const installPath = getInstalledSkillPath(repoRoot);
58
- const bundledRepoSkill = await hasBundledRepoSkill(repoRoot);
90
+ const targetRoot = path.resolve(startDir, options.target ?? ".");
91
+ await ensureDirectory(targetRoot);
92
+
93
+ const installPath = getInstalledSkillPath(targetRoot);
94
+ const existingInstall = await hasInstalledSkill(targetRoot);
95
+ const sourceManifest = await getSourceBundleManifest(resolvedBundle);
96
+
97
+ if (existingInstall && options.force !== true) {
98
+ const installedManifest = await createWorkshopBundleManifestFromDirectory(installPath);
99
+ if (installedManifest.contentHash === sourceManifest.contentHash) {
100
+ return {
101
+ installPath,
102
+ skillName: WORKSHOP_SKILL_NAME,
103
+ mode: "already_current",
104
+ sourceMode: resolvedBundle.mode,
105
+ targetRoot,
106
+ };
107
+ }
108
+
109
+ await fs.rm(installPath, { recursive: true, force: true });
59
110
 
60
- if (bundledRepoSkill) {
61
111
  return {
62
- repoRoot,
63
- installPath,
64
- skillName: SKILL_NAME,
65
- mode: "already_bundled",
112
+ ...(await installFreshBundle(resolvedBundle, installPath, targetRoot)),
113
+ mode: "refreshed",
66
114
  };
67
115
  }
68
116
 
69
- if ((await pathExists(installPath)) && options.force !== true) {
70
- throw new SkillInstallError(
71
- `Skill already installed at ${installPath}. Re-run with --force to replace it.`,
72
- { code: "already_installed" },
73
- );
117
+ if (existingInstall && options.force === true) {
118
+ await fs.rm(installPath, { recursive: true, force: true });
74
119
  }
75
120
 
76
- if (options.force === true) {
77
- await fs.rm(installPath, { recursive: true, force: true });
121
+ const result = await installFreshBundle(resolvedBundle, installPath, targetRoot);
122
+ if (existingInstall && options.force === true) {
123
+ return {
124
+ ...result,
125
+ mode: "refreshed",
126
+ };
78
127
  }
79
128
 
80
- await fs.mkdir(installPath, { recursive: true });
81
- await fs.cp(path.join(repoRoot, "workshop-skill"), path.join(installPath, "workshop-skill"), { recursive: true });
82
- await fs.cp(path.join(repoRoot, "content"), path.join(installPath, "content"), { recursive: true });
83
- await fs.cp(path.join(repoRoot, "workshop-blueprint"), path.join(installPath, "workshop-blueprint"), { recursive: true });
84
- await fs.rm(path.join(installPath, "workshop-skill", "SKILL.md"), { force: true });
85
- await fs.mkdir(path.join(installPath, "docs"), { recursive: true });
86
- await fs.copyFile(path.join(repoRoot, "workshop-skill", "SKILL.md"), path.join(installPath, "SKILL.md"));
87
- await fs.copyFile(
88
- path.join(repoRoot, "docs", "workshop-event-context-contract.md"),
89
- path.join(installPath, "docs", "workshop-event-context-contract.md"),
90
- );
91
- await fs.copyFile(
92
- path.join(repoRoot, "docs", "harness-cli-foundation.md"),
93
- path.join(installPath, "docs", "harness-cli-foundation.md"),
94
- );
129
+ return result;
130
+ }
131
+
132
+ async function installFreshBundle(resolvedBundle, installPath, targetRoot) {
133
+ await fs.mkdir(path.dirname(installPath), { recursive: true });
134
+ await installFromResolvedBundle(resolvedBundle, installPath);
95
135
 
96
136
  return {
97
- repoRoot,
98
137
  installPath,
99
- skillName: SKILL_NAME,
138
+ skillName: WORKSHOP_SKILL_NAME,
100
139
  mode: "installed",
140
+ sourceMode: resolvedBundle.mode,
141
+ targetRoot,
101
142
  };
102
143
  }