Adding many items
Write each item’s text as a markdown file in a scratch folder, then run one
primum add per item. --body-file reads the text from a
file, so nothing has to be quoted on the command line.
dir=$(mktemp -d)
cat > "$dir/csv.md" <<'END'## Why
Sam wants the open items as CSV for the weekly review.END
cat > "$dir/crash.md" <<'END'## Steps
1. Open the board with an empty `items/` folder.2. Click "+ new".END
primum add TODO "Export open items as CSV" --impact 6 --effort 3 --body-file "$dir/csv.md"primum add BUG "Empty board crashes on + new" --urgency 8 --body-file "$dir/crash.md"rm -r "$dir"Each add takes the next number, writes items/<n>.md,
rewrites BOARD.md, and is one commit in the history. Specs and plans go
beside an item the same way:
primum doc 7 spec --file "$dir/spec.md"From standard input
Section titled “From standard input”- reads the text from standard input, which suits a script or an agent
producing text:
generate-report | primum add TODO "Weekly review findings" --body-file -