Force-update status line cache with latest increment status
Force-refreshes the status line cache to reflect latest task completion and increment status. Use when status appears stale or after completing tasks to ensure accurate progress tracking.
/plugin marketplace add anton-abyzov/specweave/plugin install sw@specweavePurpose: Force-refresh status line cache when it appears stale or after making changes.
Use When:
/sw:progressScan All Increments
.specweave/increments/Select Current Increment
Parse Task Progress
Update Cache
.specweave/state/status-line.json# Force-update status line (no arguments)
/sw:update-status
Output:
✓ Status line cache updated
Before Update (stale cache):
Status Line: [0043] ████░░░░ 5/8 tasks (2 open)
After Update (fresh cache):
Status Line: [0043] ████████ 8/8 tasks (1 open) ✓
This command is automatically called by:
/sw:progress
/sw:done
/sw:status
Performance: ~50-100ms (synchronous execution)
Cache Location: .specweave/state/status-line.json
Cache Format:
{
"current": {
"id": "0043-spec-md-desync-fix",
"name": "0043-spec-md-desync-fix",
"completed": 8,
"total": 8,
"percentage": 100
},
"openCount": 1,
"lastUpdate": "2025-11-18T15:30:00Z"
}
Source of Truth:
spec.md YAML frontmatter (NOT metadata.json)tasks.md (TaskCounter for accuracy)Atomicity: Uses temp file → rename pattern to prevent cache corruption
Status line still stale after update?
.specweave/state/status-line.json was modifiedError: "Failed to update status line"
.specweave/increments/ exists.specweave/state/Cache shows wrong increment?
created date in spec.md frontmatterCLI: src/cli/update-status-line.ts
Core Logic: src/core/status-line/status-line-updater.ts
Hook (async): plugins/specweave/hooks/lib/update-status-line.sh
Difference from Hook:
Both use same logic, different execution model.
This command ensures status line is ALWAYS fresh when you need it! ✓