diff --git a/.generated-work-records.json b/.generated-work-records.json new file mode 100644 index 0000000..f6677de --- /dev/null +++ b/.generated-work-records.json @@ -0,0 +1 @@ +{"version":1,"repo_slug":"resource-control"} diff --git a/.generated-work-records.mk b/.generated-work-records.mk new file mode 100644 index 0000000..ece7b24 --- /dev/null +++ b/.generated-work-records.mk @@ -0,0 +1,8 @@ +# Explicit opt-in recipe; no environment files or external make includes. +CUSTODIAN_SOURCE ?= /home/worsch/the-custodian +GENERATED_REPO_resource-control ?= resource-control +.PHONY: generated-work-records generated-work-records-check +generated-work-records: + python3 "$(CUSTODIAN_SOURCE)/scripts/generate_staged_work_records.py" --repo . --repo-slug "$(GENERATED_REPO_resource-control)" +generated-work-records-check: + python3 "$(CUSTODIAN_SOURCE)/scripts/generate_staged_work_records.py" --repo . --repo-slug "$(GENERATED_REPO_resource-control)" --check diff --git a/Makefile b/Makefile index 7414fa9..7257b0c 100644 --- a/Makefile +++ b/Makefile @@ -46,3 +46,10 @@ consumption-mode: settlement: @test -n "$(PERIOD)" || { echo 'PERIOD=YYYY-MM is required' >&2; exit 2; } python3 tools/settlement.py close --period $(PERIOD) + +# CUST-WP-0079-T05: staged-source generation; hook uses the isolated recipe. +.PHONY: generated-work-records generated-work-records-check +generated-work-records: + $(MAKE) --no-print-directory -f .generated-work-records.mk generated-work-records +generated-work-records-check: + $(MAKE) --no-print-directory -f .generated-work-records.mk generated-work-records-check diff --git a/SCOPE.md b/SCOPE.md index df14b3d..1191d57 100644 --- a/SCOPE.md +++ b/SCOPE.md @@ -62,3 +62,16 @@ title: Infrastructure portfolio and optimization evidence description: Normalize resource inventory, capacity, utilization, ownership and cost evidence; make portfolio-report renders the portfolio and make optimization CASE=... evaluates a supplied optimization case. Workload owners retain deployment authority and fin-hub retains booked financial authority; observations do not grant procurement or scheduling admission. keywords: [resource, inventory, capacity, allocation, forecast, cost, optimization] ``` + + +## Generated work-record index + +This repository opts into staged-source WORK-RECORDS.md generation through +`.generated-work-records.json` and the isolated `.generated-work-records.mk` +recipe. `make generated-work-records` reuses the State Hub renderer through +the Custodian adapter; `make generated-work-records-check` verifies byte-exact +agreement with staged Markdown. The pre-commit hook uses the isolated recipe, +preserves unstaged index edits by refusing them, and retains the generated-only +commit guard and existing security checks. It does not contact the hub, alter +workplan statuses or grant deployment authority. This consumes shared tooling; +it does not make this repository the provider of the generator capability.