agentleFS
drafthqdrafthq/draft/skills/upload/SKILL.md

upload

Skill40 starsChanged 4 months agoMITView on GitHub

Pre-upload gate for track handoff. Verifies review status, HLD approvals, deploy checklist, and validator chain before git upload or PR submission.

  • Commits and pushes

3 other projects use a version of this.

Adopted by

Most recently taken up by

The file

Show its rules and text

We split this skill into the rules it gives an agent

14 rules. About 0 are common, 5 are distinctive, and 9 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 9

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If no track resolves, error: "No track to upload.

    line 29
  2. Very specific:

    If missing or FAIL, stop and instruct: run /draft:review track <id> first.

    line 38
  3. Very specific:

    Run /draft:deploy-checklist track <id> when no fresh passing checklist exists.

    line 42
  4. Very specific:

    Read draft/tracks/<id>/deploy-checklist-latest.md (or timestamped sibling).

    line 46
  5. Very specific:

    If frontmatter contains status: BLOCKED, stop — checklist is not a passing gate.

    line 47
  6. Distinctive:

    Run the WS-9 chain from verification-gates.md against the track directory.

    line 52
  7. Very specific:

    When spec.md frontmatter classification.criticality is high or mission-critical:

    line 73
  8. Very specific:

    Every required row in hld.md §Approvals must have a populated Date column.

    line 75
  9. Distinctive:

    If HLD was edited after the latest signed Date, stop — re-circulate for sign-off.

    line 76
  10. Distinctive:

    When LLD was generated for the track, ensure Team Lead / QA approval rows are populated before upload (same Date rule as HLD).

    line 81
  11. Distinctive:

    After all gates pass:

    line 87
  12. Very specific:

    Run the project's upload command (git upload, git push, or gh pr create per draft/workflow.md).

    line 90
  13. Distinctive:

    If Jira is linked, sync via jira-sync.md: comment "Code uploaded for review.

    line 106
  14. Very specific:

    If new public APIs lack docs, suggest /draft:documentation api.

    line 107

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Upload for Review

Gate track completion before git upload, git push, or opening a PR for human review.

Red Flags — STOP if you're

See shared red flags.

Skill-specific:

  • Uploading without a passing /draft:review on the track
  • Skipping HLD §Approvals for criticality ∈ {high, mission-critical} tracks
  • Treating a deploy checklist with status: BLOCKED as passing
  • Pushing when validator tools report hygiene or citation drift

Upload is a gate, not a shortcut around review.


Step 1: Resolve Track

  1. Parse track <id|name> from arguments, or auto-detect the active [~] track from draft/tracks.md.
  2. Load draft/tracks/<id>/spec.md, plan.md, metadata.json, and hld.md when present.
  3. If no track resolves, error: "No track to upload. Specify track <id> or activate a track."

Step 2: Pre-Upload Verification

2.1 Review gate

  • Require review-report-latest.md on the track with verdict PASS or PASS WITH NOTES.
  • If missing or FAIL, stop and instruct: run /draft:review track <id> first.

2.2 Deploy checklist (auto-invoke)

Run /draft:deploy-checklist track <id> when no fresh passing checklist exists.

2.5 Checklist status

  • Read draft/tracks/<id>/deploy-checklist-latest.md (or timestamped sibling).
  • If frontmatter contains status: BLOCKED, stop — checklist is not a passing gate.
  • Critical unchecked items block upload.

2.3 Validator chain

Run the WS-9 chain from verification-gates.md against the track directory. Any non-zero exit aborts upload.

TRACK_DIR="draft/tracks/<id>"
DRAFT_TOOLS="${DRAFT_PLUGIN_ROOT:-$(cat ~/.cache/draft/plugin-root 2>/dev/null)}/scripts/tools"
[ -d "$DRAFT_TOOLS" ] || DRAFT_TOOLS="$(ls -d ~/.claude/plugins/cache/*/draft/*/scripts/tools 2>/dev/null | sort -V | tail -1)"
[ -d "$DRAFT_TOOLS" ] || DRAFT_TOOLS="$(ls -d ~/.claude/plugins/marketplaces/*draft*/scripts/tools 2>/dev/null | tail -1)"
[ -d "$DRAFT_TOOLS" ] || DRAFT_TOOLS="$PWD/scripts/tools"

"$DRAFT_TOOLS/check-track-hygiene.sh" "$TRACK_DIR"
"$DRAFT_TOOLS/verify-citations.sh" "$TRACK_DIR"
"$DRAFT_TOOLS/verify-doc-anchors.sh" "$TRACK_DIR"
"$DRAFT_TOOLS/diff-templates-vs-tracks.sh" "$TRACK_DIR"

Step 3: HLD / LLD Approval Gate

3.1 HLD §Approvals (high-criticality)

When spec.md frontmatter classification.criticality is high or mission-critical:

  • Every required row in hld.md §Approvals must have a populated Date column.
  • If HLD was edited after the latest signed Date, stop — re-circulate for sign-off.
  • For low / unset criticality, warn if approvers are placeholders but do not block.

3.2 LLD presence

When LLD was generated for the track, ensure Team Lead / QA approval rows are populated before upload (same Date rule as HLD).


Step 4: Upload Execution

After all gates pass:

  1. Confirm branch and commit range with the user.
  2. Run the project's upload command (git upload, git push, or gh pr create per draft/workflow.md).
  3. Capture the review URL or change ID.

Update draft/tracks/<id>/metadata.json:

{
  "lastUploaded": "<ISO-8601>",
  "uploadCount": <N+1>
}

Step 5: Post-Upload

  • If Jira is linked, sync via jira-sync.md: comment "Code uploaded for review. {URL}".
  • If new public APIs lack docs, suggest /draft:documentation api.

Cross-Skill Dispatch

  • Auto-invokes: /draft:deploy-checklist
  • Requires: /draft:review PASS (or PASS WITH NOTES)
  • Suggested by: /draft:implement (track completion), /draft:documentation (pre-upload API docs)

Graph Usage Report

Emit the canonical footer from graph-usage-report.md when graph queries were used during validation.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

Reviews can't be read right now.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.