scsh 1.41.13

Scoped Skills Helper — preflight a git repo and run its scoped skills in ephemeral containers.
# Built-in workflow demo: one step categorizes words, two parallel steps sort each list, then a
# final fan-in step commits three readable files. Shows fan-out, fan-in, typed input/output wiring,
# and commit integration with a trivially checkable result. Each step gets its inputs as env vars.
description: "Categorize and sort produce, then commit README.md, FRUITS.md, and VEGGIES.md."
params:
  WORDS:
    type: string
    required: true
    description: "Comma-separated words to categorize (e.g. apple, carrot, pear, onion)"
steps:
  categorize:
    agent:
      harness: claude
      model: sonnet
    inputs:
      WORDS: params.WORDS
    prompt: |
      The WORDS input is a comma-separated list of words. Split them into two groups —
      fruits and vegetables — and return each as a comma-separated string.
    output:
      fruits:
        type: string
      vegetables:
        type: string
  sort_fruits:
    needs: categorize
    agent:
      harness: claude
      model: sonnet
    inputs:
      LIST: categorize.fruits
    prompt: |
      The LIST input is a comma-separated list. Return it sorted alphabetically, as a
      comma-separated string.
    output:
      sorted:
        type: string
  sort_vegetables:
    needs: categorize
    agent:
      harness: claude
      model: sonnet
    inputs:
      LIST: categorize.vegetables
    prompt: |
      The LIST input is a comma-separated list. Return it sorted alphabetically, as a
      comma-separated string.
    output:
      sorted:
        type: string
  write_files:
    needs: sort_fruits, sort_vegetables
    agent:
      harness: claude
      model: sonnet
    commits: true
    inputs:
      FRUITS: sort_fruits.sorted
      VEGGIES: sort_vegetables.sorted
    prompt: |
      FRUITS and VEGGIES are alphabetically sorted comma-separated lists from the two parallel
      sorter steps. Create exactly these three files at the repository root:

      1. `README.md`:

         # Produce

         This repository was generated by the `scsh` fruits workflow.

         - [Fruits](FRUITS.md)
         - [Veggies](VEGGIES.md)

      2. `FRUITS.md`: start with `# Fruits`, then one `- item` line per trimmed, non-empty FRUITS
         item, preserving the supplied order. If the list is empty, write `_None._` instead.
      3. `VEGGIES.md`: start with `# Veggies`, then one `- item` line per trimmed, non-empty
         VEGGIES item, preserving the supplied order. If the list is empty, write `_None._`
         instead.

      Commit ONLY `README.md`, `FRUITS.md`, and `VEGGIES.md` with the exact message
      `fruits: add sorted produce lists`. Do not touch any other file and do not use the network.
      Return `committed: true` only after the commit succeeds.
    output:
      committed:
        type: bool