Move a completed project or inactive area to the archive directory.
Resolve the journal path:
JORNAL="${JORNAL:-$HOME/para/areas/dev/gh/ak/journal}"Identify the target. The user says
/archive <slug>. Match against:
$JORNAL/projects/<slug>.md$JORNAL/areas/<slug>.mdRead the matched file. Show:
[ ], completed [x],
waiting [~], cancelled [-]If there are open [ ] or waiting [~]
tasks, ask the user what to do:
[-] cancelled?[>] to another project/area?[x]?Once confirmed, move the file:
mv "$JORNAL/projects/<slug>.md" "$JORNAL/archive/<slug>.md"Update _index.md:
projects/_index.md or
areas/_index.mdarchive/_index.md with today's dateCommit:
cd "$JORNAL" && git add projects/ areas/ archive/ && git commit -m "archive: close <slug>"Archived:
archive/<slug>.md