release-skill 0.1.1 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/.claude-plugin/marketplace.json +1 -1
  2. package/.claude-plugin/plugin.json +2 -2
  3. package/.codex-plugin/plugin.json +3 -3
  4. package/CHANGELOG.md +89 -0
  5. package/INSTALL.md +216 -5
  6. package/INSTALL.zh-CN.md +358 -0
  7. package/README.md +411 -67
  8. package/README.zh-CN.md +377 -59
  9. package/adapters/claude/.claude-plugin/marketplace.json +1 -1
  10. package/adapters/claude/.claude-plugin/plugin.json +1 -1
  11. package/adapters/claude/bin/release-skill.bundle.mjs +79284 -0
  12. package/adapters/claude/bin/release-skill.mjs +34 -0
  13. package/adapters/claude/native/safe-write/binding.gyp +40 -0
  14. package/adapters/claude/native/safe-write/prebuilds/darwin-arm64/safe_write.node +0 -0
  15. package/adapters/claude/native/safe-write/prebuilds.json +24 -0
  16. package/adapters/claude/native/safe-write/src/safe_write.cc +2032 -0
  17. package/adapters/claude/schemas/.render-manifest.json +37 -0
  18. package/adapters/claude/schemas/approval-record.schema.json +115 -0
  19. package/adapters/claude/schemas/artifact-lock.schema.json +111 -0
  20. package/adapters/claude/schemas/artifact-plan.schema.json +52 -0
  21. package/adapters/claude/schemas/artifact-policy.schema.json +76 -0
  22. package/adapters/claude/schemas/evidence-event.schema.json +89 -0
  23. package/adapters/claude/schemas/release-plan.schema.json +860 -0
  24. package/adapters/claude/schemas/release-project.schema.json +736 -0
  25. package/adapters/claude/schemas/release-run.schema.json +342 -0
  26. package/adapters/claude/skills/release-assess/SKILL.md +5 -6
  27. package/adapters/claude/skills/release-help/SKILL.md +14 -18
  28. package/adapters/claude/skills/release-prepare/SKILL.md +16 -6
  29. package/adapters/claude/skills/release-publish/SKILL.md +7 -7
  30. package/adapters/claude/skills/release-reconcile/SKILL.md +6 -6
  31. package/adapters/claude/skills/release-setup/SKILL.md +95 -0
  32. package/adapters/claude/skills/release-verify/SKILL.md +7 -7
  33. package/adapters/codex/.codex-plugin/plugin.json +2 -2
  34. package/adapters/codex/bin/release-skill.bundle.mjs +79284 -0
  35. package/adapters/codex/bin/release-skill.mjs +34 -0
  36. package/adapters/codex/native/safe-write/binding.gyp +40 -0
  37. package/adapters/codex/native/safe-write/prebuilds/darwin-arm64/safe_write.node +0 -0
  38. package/adapters/codex/native/safe-write/prebuilds.json +24 -0
  39. package/adapters/codex/native/safe-write/src/safe_write.cc +2032 -0
  40. package/adapters/codex/schemas/.render-manifest.json +37 -0
  41. package/adapters/codex/schemas/approval-record.schema.json +115 -0
  42. package/adapters/codex/schemas/artifact-lock.schema.json +111 -0
  43. package/adapters/codex/schemas/artifact-plan.schema.json +52 -0
  44. package/adapters/codex/schemas/artifact-policy.schema.json +76 -0
  45. package/adapters/codex/schemas/evidence-event.schema.json +89 -0
  46. package/adapters/codex/schemas/release-plan.schema.json +860 -0
  47. package/adapters/codex/schemas/release-project.schema.json +736 -0
  48. package/adapters/codex/schemas/release-run.schema.json +342 -0
  49. package/adapters/codex/skills/release-assess/SKILL.md +12 -6
  50. package/adapters/codex/skills/release-help/SKILL.md +21 -18
  51. package/adapters/codex/skills/release-prepare/SKILL.md +23 -6
  52. package/adapters/codex/skills/release-publish/SKILL.md +14 -7
  53. package/adapters/codex/skills/release-reconcile/SKILL.md +13 -6
  54. package/adapters/codex/skills/release-setup/SKILL.md +102 -0
  55. package/adapters/codex/skills/release-verify/SKILL.md +14 -7
  56. package/bin/release-skill-cli.mjs +807 -0
  57. package/bin/release-skill.bundle.mjs +79284 -0
  58. package/bin/release-skill.mjs +23 -732
  59. package/native/safe-write/prebuilds/darwin-arm64/safe_write.node +0 -0
  60. package/native/safe-write/prebuilds.json +22 -2
  61. package/native/safe-write/src/safe_write.cc +11 -2
  62. package/package.json +8 -2
  63. package/references/02-project-config.md +55 -4
  64. package/references/05-evidence-and-errors.md +6 -2
  65. package/schemas/release-plan.schema.json +556 -65
  66. package/schemas/release-project.schema.json +406 -29
  67. package/schemas/release-run.schema.json +165 -18
  68. package/scripts/build-bundle.mjs +133 -0
  69. package/skills/release-assess/SKILL.md +5 -6
  70. package/skills/release-help/SKILL.md +14 -18
  71. package/skills/release-prepare/SKILL.md +16 -6
  72. package/skills/release-publish/SKILL.md +7 -7
  73. package/skills/release-reconcile/SKILL.md +6 -6
  74. package/skills/release-setup/SKILL.md +95 -0
  75. package/skills/release-verify/SKILL.md +7 -7
  76. package/skills-src/release-assess/SKILL.md +5 -6
  77. package/skills-src/release-help/SKILL.md +14 -18
  78. package/skills-src/release-prepare/SKILL.md +16 -6
  79. package/skills-src/release-publish/SKILL.md +7 -7
  80. package/skills-src/release-reconcile/SKILL.md +6 -6
  81. package/skills-src/release-setup/SKILL.md +95 -0
  82. package/skills-src/release-verify/SKILL.md +7 -7
  83. package/src/adapters/contract.mjs +3 -0
  84. package/src/adapters/git-github.mjs +84 -2
  85. package/src/adapters/npm.mjs +5 -13
  86. package/src/adapters/plugin-marketplace.mjs +132 -52
  87. package/src/adapters/push-snapshot.mjs +84 -17
  88. package/src/artifacts/policy.mjs +4 -7
  89. package/src/artifacts/safe-fs-backend-internal.mjs +69 -21
  90. package/src/commands/prepare.mjs +244 -20
  91. package/src/commands/publish.mjs +46 -0
  92. package/src/commands/reconcile.mjs +152 -0
  93. package/src/commands/setup.mjs +1525 -0
  94. package/src/commands/verify.mjs +122 -26
  95. package/src/core/approval.mjs +4 -6
  96. package/src/core/config.mjs +42 -8
  97. package/src/core/errors.mjs +4 -0
  98. package/src/core/pkg-root.mjs +22 -0
  99. package/src/core/plan.mjs +132 -4
  100. package/src/core/previous-public-baseline.mjs +21 -1
  101. package/src/core/run.mjs +4 -4
  102. package/src/core/trusted-resource.mjs +96 -0
  103. package/src/core/verification-gates.mjs +451 -0
  104. package/src/docs/version-gate.mjs +164 -0
  105. package/src/producers/build-adapters.mjs +512 -55
  106. package/src/snapshot/frozen.mjs +221 -7
  107. package/src/snapshot/public-map.mjs +7 -4
  108. package/src/snapshot/scan.mjs +2 -1
@@ -0,0 +1,37 @@
1
+ {
2
+ "source": "schemas",
3
+ "files": {
4
+ "approval-record.schema.json": {
5
+ "digest": "38df0f095cc4b5be650a04513f8ea10cef5a6c3d0780ab38b0c5ee559d6ac7a5",
6
+ "bytes": 2611
7
+ },
8
+ "artifact-lock.schema.json": {
9
+ "digest": "6a5f4c826540b849571f173118bcbd778dfaceb4133034036ae565c3e9e353e5",
10
+ "bytes": 2729
11
+ },
12
+ "artifact-plan.schema.json": {
13
+ "digest": "f2166b1ec48a99135c0d55e5bacf8d74ed80d0b8cb46837819e295fa310979df",
14
+ "bytes": 1546
15
+ },
16
+ "artifact-policy.schema.json": {
17
+ "digest": "fa28b3856f2ed48b666458120c9b9d84d42c9ebfbec13bc866e8d71ecef6dea7",
18
+ "bytes": 2117
19
+ },
20
+ "evidence-event.schema.json": {
21
+ "digest": "b7e14522a5aba818cab191545f23d2323be0e4c80566e9d3e4da576103a00490",
22
+ "bytes": 2390
23
+ },
24
+ "release-plan.schema.json": {
25
+ "digest": "3647a554d7f8b1041078301b4de06c9aade0e1083ba8f6492cf4d3a825ea40ef",
26
+ "bytes": 4084
27
+ },
28
+ "release-project.schema.json": {
29
+ "digest": "6ae488bbad12563323892cc65f236a0ca3443aa6c0f4a17d69095a5c1af2574e",
30
+ "bytes": 6218
31
+ },
32
+ "release-run.schema.json": {
33
+ "digest": "eeb16507f0d852ed1c53b0fbeeeda0ab1c15abea63554d6f4c127f75ca1dc673",
34
+ "bytes": 4037
35
+ }
36
+ }
37
+ }
@@ -0,0 +1,115 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "https://release-skill.dev/schemas/approval-record/v1",
4
+ "title": "Approval Record",
5
+ "description": "Schema for human approval record bound to a frozen release plan",
6
+ "type": "object",
7
+ "required": [
8
+ "planDigest",
9
+ "baseline",
10
+ "approvedActions",
11
+ "actor",
12
+ "approvedAt",
13
+ "expiresAt"
14
+ ],
15
+ "anyOf": [
16
+ { "required": ["targetVersion"] },
17
+ { "required": ["unitVersions"] }
18
+ ],
19
+ "additionalProperties": false,
20
+ "properties": {
21
+ "planDigest": {
22
+ "type": "string",
23
+ "minLength": 1,
24
+ "description": "SHA-256 digest of the frozen release plan"
25
+ },
26
+ "baseline": {
27
+ "type": "object",
28
+ "required": ["gitTreeHash"],
29
+ "additionalProperties": false,
30
+ "properties": {
31
+ "gitTreeHash": {
32
+ "type": "string",
33
+ "minLength": 1,
34
+ "description": "Git tree hash at plan freeze time"
35
+ },
36
+ "workspaceDigest": {
37
+ "type": "string",
38
+ "minLength": 1,
39
+ "description": "Deterministic digest of workspace file state at plan freeze time"
40
+ },
41
+ "workspaceDigestAlgorithm": {
42
+ "type": "string",
43
+ "const": "git-workspace-v2",
44
+ "description": "Versioned algorithm authority for workspaceDigest"
45
+ }
46
+ }
47
+ },
48
+ "targetVersion": {
49
+ "type": "string",
50
+ "minLength": 1,
51
+ "description": "Target release version approved"
52
+ },
53
+ "unitVersions": {
54
+ "type": "object",
55
+ "minProperties": 1,
56
+ "additionalProperties": {
57
+ "type": "string",
58
+ "minLength": 1
59
+ },
60
+ "description": "Exact unit-id to target-version authority for multi-unit releases"
61
+ },
62
+ "approvedActions": {
63
+ "type": "array",
64
+ "minItems": 1,
65
+ "items": {
66
+ "type": "string",
67
+ "minLength": 1
68
+ },
69
+ "uniqueItems": true,
70
+ "description": "List of approved external actions (no wildcards)"
71
+ },
72
+ "actor": {
73
+ "type": "string",
74
+ "minLength": 1,
75
+ "description": "Identity of the approver"
76
+ },
77
+ "approvedAt": {
78
+ "type": "string",
79
+ "format": "date-time",
80
+ "description": "ISO 8601 timestamp when approval was granted"
81
+ },
82
+ "expiresAt": {
83
+ "type": "string",
84
+ "format": "date-time",
85
+ "description": "ISO 8601 timestamp when approval expires (max 24h after approvedAt)"
86
+ },
87
+ "exceptions": {
88
+ "type": "array",
89
+ "items": {
90
+ "type": "object",
91
+ "required": ["rule", "reason", "responsible", "expiresAt"],
92
+ "additionalProperties": false,
93
+ "properties": {
94
+ "rule": {
95
+ "type": "string",
96
+ "minLength": 1
97
+ },
98
+ "reason": {
99
+ "type": "string",
100
+ "minLength": 1
101
+ },
102
+ "responsible": {
103
+ "type": "string",
104
+ "minLength": 1
105
+ },
106
+ "expiresAt": {
107
+ "type": "string",
108
+ "format": "date-time"
109
+ }
110
+ }
111
+ },
112
+ "description": "Exception waivers with reason, responsible person, and expiration"
113
+ }
114
+ }
115
+ }
@@ -0,0 +1,111 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "https://release-skill.dev/artifact-lock.schema.json",
4
+ "title": "ArtifactLock",
5
+ "description": "Reachable accepted artifact manifest. Absolute repository paths are never authoritative.",
6
+ "type": "object",
7
+ "required": [
8
+ "lockVersion",
9
+ "repositoryId",
10
+ "repositoryIdentity",
11
+ "policyDigest",
12
+ "acceptanceId",
13
+ "acceptedArtifactManifestDigest",
14
+ "entries",
15
+ "acceptedAt",
16
+ "acceptedBy"
17
+ ],
18
+ "additionalProperties": false,
19
+ "properties": {
20
+ "apiVersion": {
21
+ "type": "string",
22
+ "const": "release-skill.dev/artifact-lock/v1"
23
+ },
24
+ "lockVersion": {
25
+ "type": "integer",
26
+ "const": 1
27
+ },
28
+ "repositoryId": {
29
+ "type": "string",
30
+ "minLength": 1
31
+ },
32
+ "repositoryIdentity": {
33
+ "type": "object",
34
+ "required": ["remoteUrlHash"],
35
+ "additionalProperties": false,
36
+ "properties": {
37
+ "remoteUrlHash": {
38
+ "type": "string",
39
+ "pattern": "^sha256:[a-f0-9]{64}$"
40
+ }
41
+ }
42
+ },
43
+ "policyDigest": {
44
+ "type": "string",
45
+ "pattern": "^sha256:[a-f0-9]{64}$"
46
+ },
47
+ "acceptanceId": {
48
+ "type": "string",
49
+ "minLength": 1
50
+ },
51
+ "acceptedArtifactManifestDigest": {
52
+ "type": "string",
53
+ "pattern": "^sha256:[a-f0-9]{64}$"
54
+ },
55
+ "entries": {
56
+ "type": "object",
57
+ "minProperties": 1,
58
+ "additionalProperties": {
59
+ "type": "object",
60
+ "required": ["path", "type", "mode", "gitOid", "sha256"],
61
+ "additionalProperties": false,
62
+ "properties": {
63
+ "path": {
64
+ "type": "string",
65
+ "minLength": 1
66
+ },
67
+ "type": {
68
+ "type": "string",
69
+ "enum": ["blob", "tree"]
70
+ },
71
+ "mode": {
72
+ "type": "string",
73
+ "pattern": "^(100644|100755|040000)$"
74
+ },
75
+ "gitOid": {
76
+ "type": "string",
77
+ "pattern": "^[a-f0-9]{40,64}$"
78
+ },
79
+ "sha256": {
80
+ "type": "string",
81
+ "pattern": "^(sha256:)?[a-f0-9]{64}$"
82
+ },
83
+ "size": {
84
+ "type": "integer",
85
+ "minimum": 0
86
+ },
87
+ "manifestDigest": {
88
+ "type": "string",
89
+ "pattern": "^sha256:[a-f0-9]{64}$"
90
+ },
91
+ "ownership": {
92
+ "type": "string",
93
+ "enum": ["human", "generated", "mixed"]
94
+ },
95
+ "mergeDriver": {
96
+ "type": "string",
97
+ "minLength": 1
98
+ }
99
+ }
100
+ }
101
+ },
102
+ "acceptedAt": {
103
+ "type": "string",
104
+ "format": "date-time"
105
+ },
106
+ "acceptedBy": {
107
+ "type": "string",
108
+ "minLength": 1
109
+ }
110
+ }
111
+ }
@@ -0,0 +1,52 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "https://release-skill.dev/artifact-plan.schema.json",
4
+ "title": "ArtifactPlan",
5
+ "description": "Read-only inspection plan for artifact state and next action.",
6
+ "type": "object",
7
+ "required": [
8
+ "apiVersion",
9
+ "operation",
10
+ "bindings",
11
+ "artifacts",
12
+ "safeToWrite",
13
+ "targetUnchanged",
14
+ "nextAction",
15
+ "planDigest"
16
+ ],
17
+ "additionalProperties": false,
18
+ "properties": {
19
+ "apiVersion": { "type": "string", "const": "release-skill.dev/artifact-plan/v1" },
20
+ "operation": { "type": "string", "enum": ["inspect", "init", "status"] },
21
+ "bindings": {
22
+ "type": "object",
23
+ "required": [
24
+ "repositoryIdentity",
25
+ "policyDigest",
26
+ "baseManifestDigest",
27
+ "currentManifestDigest",
28
+ "producerClosureDigest"
29
+ ],
30
+ "additionalProperties": false,
31
+ "properties": {
32
+ "repositoryIdentity": { "type": "string" },
33
+ "policyDigest": { "type": "string" },
34
+ "baseManifestDigest": { "type": "string" },
35
+ "currentManifestDigest": { "type": "string" },
36
+ "producerClosureDigest": { "type": "string" }
37
+ }
38
+ },
39
+ "artifacts": { "type": "array" },
40
+ "safeToWrite": { "type": "boolean" },
41
+ "targetUnchanged": { "type": "boolean" },
42
+ "nextAction": {
43
+ "type": "object",
44
+ "required": ["command"],
45
+ "additionalProperties": false,
46
+ "properties": {
47
+ "command": { "type": "string" }
48
+ }
49
+ },
50
+ "planDigest": { "type": "string" }
51
+ }
52
+ }
@@ -0,0 +1,76 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "https://release-skill.dev/artifact-policy.schema.json",
4
+ "title": "ArtifactPolicy",
5
+ "description": "Closed-world artifact policy defining repository identity, inventory, and artifact definitions.",
6
+ "type": "object",
7
+ "required": ["repository", "inventory", "artifacts"],
8
+ "additionalProperties": false,
9
+ "properties": {
10
+ "repository": {
11
+ "type": "object",
12
+ "required": ["id"],
13
+ "additionalProperties": false,
14
+ "properties": {
15
+ "id": { "type": "string", "minLength": 1 }
16
+ }
17
+ },
18
+ "inventory": {
19
+ "type": "object",
20
+ "required": ["roots", "defaultOwnership"],
21
+ "additionalProperties": false,
22
+ "properties": {
23
+ "roots": {
24
+ "type": "array",
25
+ "items": { "type": "string", "minLength": 1 },
26
+ "minItems": 1
27
+ },
28
+ "defaultOwnership": { "type": "string", "enum": ["human", "generated"] }
29
+ }
30
+ },
31
+ "artifacts": {
32
+ "type": "array",
33
+ "minItems": 1,
34
+ "items": {
35
+ "type": "object",
36
+ "required": ["id", "type"],
37
+ "properties": {
38
+ "id": { "type": "string", "minLength": 1 },
39
+ "type": { "type": "string", "enum": ["declared", "generated"] },
40
+ "sourcePath": { "type": "string" },
41
+ "ownership": { "type": "string", "enum": ["human", "generated"] },
42
+ "producer": { "type": "string", "minLength": 1 },
43
+ "sourceArtifacts": {
44
+ "type": "array",
45
+ "items": { "type": "string", "minLength": 1 },
46
+ "minItems": 1
47
+ },
48
+ "adoptionRoutes": {
49
+ "type": "array",
50
+ "items": {
51
+ "type": "object",
52
+ "required": ["target", "sourceArtifact", "mode"],
53
+ "additionalProperties": false,
54
+ "properties": {
55
+ "target": { "type": "string", "minLength": 1 },
56
+ "sourceArtifact": { "type": "string", "minLength": 1 },
57
+ "mode": { "type": "string", "enum": ["exact-copy"] }
58
+ }
59
+ },
60
+ "minItems": 1
61
+ }
62
+ },
63
+ "oneOf": [
64
+ {
65
+ "properties": { "type": { "const": "declared" } },
66
+ "required": ["sourcePath"]
67
+ },
68
+ {
69
+ "properties": { "type": { "const": "generated" } },
70
+ "required": ["producer", "sourceArtifacts", "adoptionRoutes"]
71
+ }
72
+ ]
73
+ }
74
+ }
75
+ }
76
+ }
@@ -0,0 +1,89 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "$id": "https://release-skill.dev/schemas/evidence-event/v1",
4
+ "title": "Evidence Event",
5
+ "description": "Schema for JSONL evidence events produced during release execution",
6
+ "type": "object",
7
+ "required": [
8
+ "schemaVersion",
9
+ "runId",
10
+ "sequence",
11
+ "timestamp",
12
+ "command",
13
+ "phase",
14
+ "status"
15
+ ],
16
+ "additionalProperties": false,
17
+ "properties": {
18
+ "schemaVersion": {
19
+ "type": "integer",
20
+ "const": 1,
21
+ "description": "Event format version"
22
+ },
23
+ "runId": {
24
+ "type": "string",
25
+ "minLength": 1,
26
+ "description": "Unique identifier for the run (UUID)"
27
+ },
28
+ "sequence": {
29
+ "type": "integer",
30
+ "minimum": 1,
31
+ "description": "Event sequence number within the run, starting from 1"
32
+ },
33
+ "timestamp": {
34
+ "type": "string",
35
+ "format": "date-time",
36
+ "description": "ISO 8601 UTC timestamp of the event"
37
+ },
38
+ "command": {
39
+ "type": "string",
40
+ "enum": ["assess", "prepare", "publish", "reconcile", "verify"],
41
+ "description": "The command that triggered this event"
42
+ },
43
+ "phase": {
44
+ "type": "string",
45
+ "minLength": 1,
46
+ "description": "Current execution phase identifier"
47
+ },
48
+ "status": {
49
+ "type": "string",
50
+ "enum": ["started", "succeeded", "failed", "skipped"],
51
+ "description": "Status value of this event"
52
+ },
53
+ "error": {
54
+ "type": ["object", "null"],
55
+ "description": "Error details when status is failed",
56
+ "additionalProperties": false,
57
+ "properties": {
58
+ "code": {
59
+ "type": "string",
60
+ "enum": [
61
+ "CONFIG_INVALID",
62
+ "BASELINE_CHANGED",
63
+ "DIRTY_SCOPE_CONFLICT",
64
+ "GATE_FAILED",
65
+ "AUTH_MISSING",
66
+ "REMOTE_CONFLICT",
67
+ "HOOK_TIMEOUT",
68
+ "PARTIAL_RELEASE",
69
+ "POST_PUBLISH_VERIFY_FAILED"
70
+ ],
71
+ "description": "Stable error code"
72
+ },
73
+ "message": {
74
+ "type": "string",
75
+ "description": "Human-readable error message"
76
+ }
77
+ }
78
+ },
79
+ "duration": {
80
+ "type": "integer",
81
+ "minimum": 0,
82
+ "description": "Phase duration in milliseconds"
83
+ },
84
+ "details": {
85
+ "type": "object",
86
+ "description": "Phase-specific supplementary information"
87
+ }
88
+ }
89
+ }