You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Simplify from 4 JSON files to 2:
- upstream_versions.json: latest available versions (committed)
- local_state.json: machine-specific state (gitignored)
Removed:
- latest_versions.json: merged into upstream_versions.json
- tools_snapshot.json: now gitignored (generated on demand)
Updated all documentation references from latest_versions.json
to upstream_versions.json.
Note: docs still reference __hints__ feature which was removed
during prior refactoring - needs separate cleanup pass.
Copy file name to clipboardExpand all lines: README.md
+8-15Lines changed: 8 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -730,24 +730,17 @@ make audit
730
730
- Some package managers (like Go) don't have built-in bulk update mechanisms - manual updates are required
731
731
- The script gracefully handles missing package managers (skips them)
732
732
733
-
## Caching
733
+
## Data Files
734
734
735
-
- Manual baseline (committed): `latest_versions.json` in this repo (override with `CLI_AUDIT_MANUAL_FILE`). Used as the primary source in offline mode; also used as a fallback when online lookups fail. Example content:
735
+
The audit system uses two JSON files:
736
736
737
-
```json
738
-
{
739
-
"rust": "1.89.0",
740
-
"jq": "jq-1.8.1",
741
-
"parallel": "20240322"
742
-
}
743
-
```
744
-
745
-
- Auto-updates: when an online lookup succeeds, the tool writes the discovered latest value back into `latest_versions.json` (toggle with `CLI_AUDIT_WRITE_MANUAL=0`).
746
-
- Offline behavior: set `CLI_AUDIT_OFFLINE=1` to use `latest_versions.json` exclusively.
747
-
748
-
### Lookup hints
737
+
| File | Purpose | Git Tracked |
738
+
|------|---------|-------------|
739
+
|`upstream_versions.json`| Latest available versions from upstream sources | Yes (committed) |
740
+
|`local_state.json`| Machine-specific installed tool versions | No (gitignored) |
749
741
750
-
To speed up future runs, the audit records which upstream retrieval method worked last per tool. These hints are stored inside `latest_versions.json` under the special key `"__hints__"`. They help prioritize the fastest working method on subsequent runs and are safe to edit or remove; they will be rebuilt.
742
+
-**Offline mode**: Set `CLI_AUDIT_OFFLINE=1` to use cached `upstream_versions.json` without network calls
743
+
-**Baseline refresh**: Run `python audit.py --update-baseline` to update upstream versions
0 commit comments