multimodel-dev-os 2.9.1 → 3.0.0

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.
@@ -1,248 +1,248 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
3
- <url>
4
- <loc>https://rizvee.github.io/multimodel-dev-os/</loc>
5
- <changefreq>daily</changefreq>
6
- <priority>1.0</priority>
7
- </url>
8
- <url>
9
- <loc>https://rizvee.github.io/multimodel-dev-os/quickstart</loc>
10
- <changefreq>weekly</changefreq>
11
- <priority>0.8</priority>
12
- </url>
13
- <url>
14
- <loc>https://rizvee.github.io/multimodel-dev-os/templates/</loc>
15
- <changefreq>weekly</changefreq>
16
- <priority>0.8</priority>
17
- </url>
18
- <url>
19
- <loc>https://rizvee.github.io/multimodel-dev-os/protocol</loc>
20
- <changefreq>weekly</changefreq>
21
- <priority>0.7</priority>
22
- </url>
23
- <url>
24
- <loc>https://rizvee.github.io/multimodel-dev-os/stable-protocol</loc>
25
- <changefreq>weekly</changefreq>
26
- <priority>0.9</priority>
27
- </url>
28
- <url>
29
- <loc>https://rizvee.github.io/multimodel-dev-os/compatibility</loc>
30
- <changefreq>weekly</changefreq>
31
- <priority>0.7</priority>
32
- </url>
33
- <url>
34
- <loc>https://rizvee.github.io/multimodel-dev-os/migration-guide</loc>
35
- <changefreq>weekly</changefreq>
36
- <priority>0.7</priority>
37
- </url>
38
- <url>
39
- <loc>https://rizvee.github.io/multimodel-dev-os/cost-optimization</loc>
40
- <changefreq>weekly</changefreq>
41
- <priority>0.8</priority>
42
- </url>
43
- <url>
44
- <loc>https://rizvee.github.io/multimodel-dev-os/5-day-roadmap</loc>
45
- <changefreq>monthly</changefreq>
46
- <priority>0.6</priority>
47
- </url>
48
- <url>
49
- <loc>https://rizvee.github.io/multimodel-dev-os/case-studies/</loc>
50
- <changefreq>weekly</changefreq>
51
- <priority>0.8</priority>
52
- </url>
53
- <url>
54
- <loc>https://rizvee.github.io/multimodel-dev-os/demo</loc>
55
- <changefreq>weekly</changefreq>
56
- <priority>0.7</priority>
57
- </url>
58
- <url>
59
- <loc>https://rizvee.github.io/multimodel-dev-os/faq</loc>
60
- <changefreq>weekly</changefreq>
61
- <priority>0.6</priority>
62
- </url>
63
- <url>
64
- <loc>https://rizvee.github.io/multimodel-dev-os/v2-release-checklist</loc>
65
- <changefreq>weekly</changefreq>
66
- <priority>0.6</priority>
67
- </url>
68
- <url>
69
- <loc>https://rizvee.github.io/multimodel-dev-os/model-routing</loc>
70
- <changefreq>weekly</changefreq>
71
- <priority>0.7</priority>
72
- </url>
73
- <url>
74
- <loc>https://rizvee.github.io/multimodel-dev-os/local-models</loc>
75
- <changefreq>weekly</changefreq>
76
- <priority>0.7</priority>
77
- </url>
78
- <url>
79
- <loc>https://rizvee.github.io/multimodel-dev-os/provider-strategy</loc>
80
- <changefreq>weekly</changefreq>
81
- <priority>0.7</priority>
82
- </url>
83
- <url>
84
- <loc>https://rizvee.github.io/multimodel-dev-os/agent-compatibility</loc>
85
- <changefreq>weekly</changefreq>
86
- <priority>0.7</priority>
87
- </url>
88
- <url>
89
- <loc>https://rizvee.github.io/multimodel-dev-os/adapter-authoring</loc>
90
- <changefreq>weekly</changefreq>
91
- <priority>0.7</priority>
92
- </url>
93
- <url>
94
- <loc>https://rizvee.github.io/multimodel-dev-os/template-authoring</loc>
95
- <changefreq>weekly</changefreq>
96
- <priority>0.7</priority>
97
- </url>
98
- <url>
99
- <loc>https://rizvee.github.io/multimodel-dev-os/skill-authoring</loc>
100
- <changefreq>weekly</changefreq>
101
- <priority>0.7</priority>
102
- </url>
103
- <url>
104
- <loc>https://rizvee.github.io/multimodel-dev-os/v2-migration</loc>
105
- <changefreq>weekly</changefreq>
106
- <priority>0.7</priority>
107
- </url>
108
- <url>
109
- <loc>https://rizvee.github.io/multimodel-dev-os/package-safety</loc>
110
- <changefreq>weekly</changefreq>
111
- <priority>0.7</priority>
112
- </url>
113
- <url>
114
- <loc>https://rizvee.github.io/multimodel-dev-os/registry-contribution</loc>
115
- <changefreq>weekly</changefreq>
116
- <priority>0.7</priority>
117
- </url>
118
- <url>
119
- <loc>https://rizvee.github.io/multimodel-dev-os/future-proof-architecture</loc>
120
- <changefreq>weekly</changefreq>
121
- <priority>0.7</priority>
122
- </url>
123
- <url>
124
- <loc>https://rizvee.github.io/multimodel-dev-os/self-improving-codebase</loc>
125
- <changefreq>weekly</changefreq>
126
- <priority>0.7</priority>
127
- </url>
128
- <url>
129
- <loc>https://rizvee.github.io/multimodel-dev-os/hash-compressed-memory</loc>
130
- <changefreq>weekly</changefreq>
131
- <priority>0.7</priority>
132
- </url>
133
- <url>
134
- <loc>https://rizvee.github.io/multimodel-dev-os/feedback-learning</loc>
135
- <changefreq>weekly</changefreq>
136
- <priority>0.7</priority>
137
- </url>
138
- <url>
139
- <loc>https://rizvee.github.io/multimodel-dev-os/capability-registry</loc>
140
- <changefreq>weekly</changefreq>
141
- <priority>0.7</priority>
142
- </url>
143
- <url>
144
- <loc>https://rizvee.github.io/multimodel-dev-os/tool-registry</loc>
145
- <changefreq>weekly</changefreq>
146
- <priority>0.7</priority>
147
- </url>
148
- <url>
149
- <loc>https://rizvee.github.io/multimodel-dev-os/demos/</loc>
150
- <changefreq>weekly</changefreq>
151
- <priority>0.8</priority>
152
- </url>
153
- <url>
154
- <loc>https://rizvee.github.io/multimodel-dev-os/demos/existing-repo-onboarding</loc>
155
- <changefreq>weekly</changefreq>
156
- <priority>0.8</priority>
157
- </url>
158
- <url>
159
- <loc>https://rizvee.github.io/multimodel-dev-os/demos/multi-agent-handoff</loc>
160
- <changefreq>weekly</changefreq>
161
- <priority>0.8</priority>
162
- </url>
163
- <url>
164
- <loc>https://rizvee.github.io/multimodel-dev-os/demos/safe-improvement-loop</loc>
165
- <changefreq>weekly</changefreq>
166
- <priority>0.8</priority>
167
- </url>
168
- <url>
169
- <loc>https://rizvee.github.io/multimodel-dev-os/demos/adapter-sync</loc>
170
- <changefreq>weekly</changefreq>
171
- <priority>0.8</priority>
172
- </url>
173
- <url>
174
- <loc>https://rizvee.github.io/multimodel-dev-os/demos/release-check</loc>
175
- <changefreq>weekly</changefreq>
176
- <priority>0.8</priority>
177
- </url>
178
- <url>
179
- <loc>https://rizvee.github.io/multimodel-dev-os/distribution</loc>
180
- <changefreq>weekly</changefreq>
181
- <priority>0.8</priority>
182
- </url>
183
- <url>
184
- <loc>https://rizvee.github.io/multimodel-dev-os/dashboard</loc>
185
- <changefreq>weekly</changefreq>
186
- <priority>0.7</priority>
187
- </url>
188
- <url>
189
- <loc>https://rizvee.github.io/multimodel-dev-os/plugin-hooks</loc>
190
- <changefreq>weekly</changefreq>
191
- <priority>0.7</priority>
192
- </url>
193
- <url>
194
- <loc>https://rizvee.github.io/multimodel-dev-os/plugin-authoring</loc>
195
- <changefreq>weekly</changefreq>
196
- <priority>0.7</priority>
197
- </url>
198
- <url>
199
- <loc>https://rizvee.github.io/multimodel-dev-os/tui-safety</loc>
200
- <changefreq>weekly</changefreq>
201
- <priority>0.7</priority>
202
- </url>
203
- <url>
204
- <loc>https://rizvee.github.io/multimodel-dev-os/catalog</loc>
205
- <changefreq>weekly</changefreq>
206
- <priority>0.7</priority>
207
- </url>
208
- <url>
209
- <loc>https://rizvee.github.io/multimodel-dev-os/plugin-catalog</loc>
210
- <changefreq>weekly</changefreq>
211
- <priority>0.7</priority>
212
- </url>
213
- <url>
214
- <loc>https://rizvee.github.io/multimodel-dev-os/workflow-marketplace</loc>
215
- <changefreq>weekly</changefreq>
216
- <priority>0.7</priority>
217
- </url>
218
- <url>
219
- <loc>https://rizvee.github.io/multimodel-dev-os/catalog-authoring</loc>
220
- <changefreq>weekly</changefreq>
221
- <priority>0.7</priority>
222
- </url>
223
- <url>
224
- <loc>https://rizvee.github.io/multimodel-dev-os/registry-sync</loc>
225
- <changefreq>weekly</changefreq>
226
- <priority>0.7</priority>
227
- </url>
228
- <url>
229
- <loc>https://rizvee.github.io/multimodel-dev-os/trusted-registries</loc>
230
- <changefreq>weekly</changefreq>
231
- <priority>0.7</priority>
232
- </url>
233
- <url>
234
- <loc>https://rizvee.github.io/multimodel-dev-os/registry-policy</loc>
235
- <changefreq>weekly</changefreq>
236
- <priority>0.7</priority>
237
- </url>
238
- <url>
239
- <loc>https://rizvee.github.io/multimodel-dev-os/registry-security</loc>
240
- <changefreq>weekly</changefreq>
241
- <priority>0.7</priority>
242
- </url>
243
- <url>
244
- <loc>https://rizvee.github.io/multimodel-dev-os/remote-catalog-authoring</loc>
245
- <changefreq>weekly</changefreq>
246
- <priority>0.7</priority>
247
- </url>
248
- </urlset>
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
3
+ <url>
4
+ <loc>https://rizvee.github.io/multimodel-dev-os/</loc>
5
+ <changefreq>daily</changefreq>
6
+ <priority>1.0</priority>
7
+ </url>
8
+ <url>
9
+ <loc>https://rizvee.github.io/multimodel-dev-os/quickstart</loc>
10
+ <changefreq>weekly</changefreq>
11
+ <priority>0.8</priority>
12
+ </url>
13
+ <url>
14
+ <loc>https://rizvee.github.io/multimodel-dev-os/templates/</loc>
15
+ <changefreq>weekly</changefreq>
16
+ <priority>0.8</priority>
17
+ </url>
18
+ <url>
19
+ <loc>https://rizvee.github.io/multimodel-dev-os/protocol</loc>
20
+ <changefreq>weekly</changefreq>
21
+ <priority>0.7</priority>
22
+ </url>
23
+ <url>
24
+ <loc>https://rizvee.github.io/multimodel-dev-os/stable-protocol</loc>
25
+ <changefreq>weekly</changefreq>
26
+ <priority>0.9</priority>
27
+ </url>
28
+ <url>
29
+ <loc>https://rizvee.github.io/multimodel-dev-os/compatibility</loc>
30
+ <changefreq>weekly</changefreq>
31
+ <priority>0.7</priority>
32
+ </url>
33
+ <url>
34
+ <loc>https://rizvee.github.io/multimodel-dev-os/migration-guide</loc>
35
+ <changefreq>weekly</changefreq>
36
+ <priority>0.7</priority>
37
+ </url>
38
+ <url>
39
+ <loc>https://rizvee.github.io/multimodel-dev-os/cost-optimization</loc>
40
+ <changefreq>weekly</changefreq>
41
+ <priority>0.8</priority>
42
+ </url>
43
+ <url>
44
+ <loc>https://rizvee.github.io/multimodel-dev-os/5-day-roadmap</loc>
45
+ <changefreq>monthly</changefreq>
46
+ <priority>0.6</priority>
47
+ </url>
48
+ <url>
49
+ <loc>https://rizvee.github.io/multimodel-dev-os/case-studies/</loc>
50
+ <changefreq>weekly</changefreq>
51
+ <priority>0.8</priority>
52
+ </url>
53
+ <url>
54
+ <loc>https://rizvee.github.io/multimodel-dev-os/demo</loc>
55
+ <changefreq>weekly</changefreq>
56
+ <priority>0.7</priority>
57
+ </url>
58
+ <url>
59
+ <loc>https://rizvee.github.io/multimodel-dev-os/faq</loc>
60
+ <changefreq>weekly</changefreq>
61
+ <priority>0.6</priority>
62
+ </url>
63
+ <url>
64
+ <loc>https://rizvee.github.io/multimodel-dev-os/v2-release-checklist</loc>
65
+ <changefreq>weekly</changefreq>
66
+ <priority>0.6</priority>
67
+ </url>
68
+ <url>
69
+ <loc>https://rizvee.github.io/multimodel-dev-os/model-routing</loc>
70
+ <changefreq>weekly</changefreq>
71
+ <priority>0.7</priority>
72
+ </url>
73
+ <url>
74
+ <loc>https://rizvee.github.io/multimodel-dev-os/local-models</loc>
75
+ <changefreq>weekly</changefreq>
76
+ <priority>0.7</priority>
77
+ </url>
78
+ <url>
79
+ <loc>https://rizvee.github.io/multimodel-dev-os/provider-strategy</loc>
80
+ <changefreq>weekly</changefreq>
81
+ <priority>0.7</priority>
82
+ </url>
83
+ <url>
84
+ <loc>https://rizvee.github.io/multimodel-dev-os/agent-compatibility</loc>
85
+ <changefreq>weekly</changefreq>
86
+ <priority>0.7</priority>
87
+ </url>
88
+ <url>
89
+ <loc>https://rizvee.github.io/multimodel-dev-os/adapter-authoring</loc>
90
+ <changefreq>weekly</changefreq>
91
+ <priority>0.7</priority>
92
+ </url>
93
+ <url>
94
+ <loc>https://rizvee.github.io/multimodel-dev-os/template-authoring</loc>
95
+ <changefreq>weekly</changefreq>
96
+ <priority>0.7</priority>
97
+ </url>
98
+ <url>
99
+ <loc>https://rizvee.github.io/multimodel-dev-os/skill-authoring</loc>
100
+ <changefreq>weekly</changefreq>
101
+ <priority>0.7</priority>
102
+ </url>
103
+ <url>
104
+ <loc>https://rizvee.github.io/multimodel-dev-os/v2-migration</loc>
105
+ <changefreq>weekly</changefreq>
106
+ <priority>0.7</priority>
107
+ </url>
108
+ <url>
109
+ <loc>https://rizvee.github.io/multimodel-dev-os/package-safety</loc>
110
+ <changefreq>weekly</changefreq>
111
+ <priority>0.7</priority>
112
+ </url>
113
+ <url>
114
+ <loc>https://rizvee.github.io/multimodel-dev-os/registry-contribution</loc>
115
+ <changefreq>weekly</changefreq>
116
+ <priority>0.7</priority>
117
+ </url>
118
+ <url>
119
+ <loc>https://rizvee.github.io/multimodel-dev-os/future-proof-architecture</loc>
120
+ <changefreq>weekly</changefreq>
121
+ <priority>0.7</priority>
122
+ </url>
123
+ <url>
124
+ <loc>https://rizvee.github.io/multimodel-dev-os/self-improving-codebase</loc>
125
+ <changefreq>weekly</changefreq>
126
+ <priority>0.7</priority>
127
+ </url>
128
+ <url>
129
+ <loc>https://rizvee.github.io/multimodel-dev-os/hash-compressed-memory</loc>
130
+ <changefreq>weekly</changefreq>
131
+ <priority>0.7</priority>
132
+ </url>
133
+ <url>
134
+ <loc>https://rizvee.github.io/multimodel-dev-os/feedback-learning</loc>
135
+ <changefreq>weekly</changefreq>
136
+ <priority>0.7</priority>
137
+ </url>
138
+ <url>
139
+ <loc>https://rizvee.github.io/multimodel-dev-os/capability-registry</loc>
140
+ <changefreq>weekly</changefreq>
141
+ <priority>0.7</priority>
142
+ </url>
143
+ <url>
144
+ <loc>https://rizvee.github.io/multimodel-dev-os/tool-registry</loc>
145
+ <changefreq>weekly</changefreq>
146
+ <priority>0.7</priority>
147
+ </url>
148
+ <url>
149
+ <loc>https://rizvee.github.io/multimodel-dev-os/demos/</loc>
150
+ <changefreq>weekly</changefreq>
151
+ <priority>0.8</priority>
152
+ </url>
153
+ <url>
154
+ <loc>https://rizvee.github.io/multimodel-dev-os/demos/existing-repo-onboarding</loc>
155
+ <changefreq>weekly</changefreq>
156
+ <priority>0.8</priority>
157
+ </url>
158
+ <url>
159
+ <loc>https://rizvee.github.io/multimodel-dev-os/demos/multi-agent-handoff</loc>
160
+ <changefreq>weekly</changefreq>
161
+ <priority>0.8</priority>
162
+ </url>
163
+ <url>
164
+ <loc>https://rizvee.github.io/multimodel-dev-os/demos/safe-improvement-loop</loc>
165
+ <changefreq>weekly</changefreq>
166
+ <priority>0.8</priority>
167
+ </url>
168
+ <url>
169
+ <loc>https://rizvee.github.io/multimodel-dev-os/demos/adapter-sync</loc>
170
+ <changefreq>weekly</changefreq>
171
+ <priority>0.8</priority>
172
+ </url>
173
+ <url>
174
+ <loc>https://rizvee.github.io/multimodel-dev-os/demos/release-check</loc>
175
+ <changefreq>weekly</changefreq>
176
+ <priority>0.8</priority>
177
+ </url>
178
+ <url>
179
+ <loc>https://rizvee.github.io/multimodel-dev-os/distribution</loc>
180
+ <changefreq>weekly</changefreq>
181
+ <priority>0.8</priority>
182
+ </url>
183
+ <url>
184
+ <loc>https://rizvee.github.io/multimodel-dev-os/dashboard</loc>
185
+ <changefreq>weekly</changefreq>
186
+ <priority>0.7</priority>
187
+ </url>
188
+ <url>
189
+ <loc>https://rizvee.github.io/multimodel-dev-os/plugin-hooks</loc>
190
+ <changefreq>weekly</changefreq>
191
+ <priority>0.7</priority>
192
+ </url>
193
+ <url>
194
+ <loc>https://rizvee.github.io/multimodel-dev-os/plugin-authoring</loc>
195
+ <changefreq>weekly</changefreq>
196
+ <priority>0.7</priority>
197
+ </url>
198
+ <url>
199
+ <loc>https://rizvee.github.io/multimodel-dev-os/tui-safety</loc>
200
+ <changefreq>weekly</changefreq>
201
+ <priority>0.7</priority>
202
+ </url>
203
+ <url>
204
+ <loc>https://rizvee.github.io/multimodel-dev-os/catalog</loc>
205
+ <changefreq>weekly</changefreq>
206
+ <priority>0.7</priority>
207
+ </url>
208
+ <url>
209
+ <loc>https://rizvee.github.io/multimodel-dev-os/plugin-catalog</loc>
210
+ <changefreq>weekly</changefreq>
211
+ <priority>0.7</priority>
212
+ </url>
213
+ <url>
214
+ <loc>https://rizvee.github.io/multimodel-dev-os/workflow-marketplace</loc>
215
+ <changefreq>weekly</changefreq>
216
+ <priority>0.7</priority>
217
+ </url>
218
+ <url>
219
+ <loc>https://rizvee.github.io/multimodel-dev-os/catalog-authoring</loc>
220
+ <changefreq>weekly</changefreq>
221
+ <priority>0.7</priority>
222
+ </url>
223
+ <url>
224
+ <loc>https://rizvee.github.io/multimodel-dev-os/registry-sync</loc>
225
+ <changefreq>weekly</changefreq>
226
+ <priority>0.7</priority>
227
+ </url>
228
+ <url>
229
+ <loc>https://rizvee.github.io/multimodel-dev-os/trusted-registries</loc>
230
+ <changefreq>weekly</changefreq>
231
+ <priority>0.7</priority>
232
+ </url>
233
+ <url>
234
+ <loc>https://rizvee.github.io/multimodel-dev-os/registry-policy</loc>
235
+ <changefreq>weekly</changefreq>
236
+ <priority>0.7</priority>
237
+ </url>
238
+ <url>
239
+ <loc>https://rizvee.github.io/multimodel-dev-os/registry-security</loc>
240
+ <changefreq>weekly</changefreq>
241
+ <priority>0.7</priority>
242
+ </url>
243
+ <url>
244
+ <loc>https://rizvee.github.io/multimodel-dev-os/remote-catalog-authoring</loc>
245
+ <changefreq>weekly</changefreq>
246
+ <priority>0.7</priority>
247
+ </url>
248
+ </urlset>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "multimodel-dev-os",
3
- "version": "2.9.1",
3
+ "version": "3.0.0",
4
4
  "bin": {
5
5
  "multimodel-dev-os": "bin/multimodel-dev-os.js"
6
6
  },
Binary file
Binary file
@@ -21,18 +21,40 @@ if (process.env.MMDO_ALLOW_PUBLISH !== 'true') {
21
21
  process.exit(1);
22
22
  }
23
23
 
24
- // 2. Enforce package version begins with '2.'
24
+ // 2. Read and validate package version
25
25
  try {
26
26
  const packageJsonPath = join(projectRoot, 'package.json');
27
27
  if (existsSync(packageJsonPath)) {
28
28
  const pkgData = JSON.parse(readFileSync(packageJsonPath, 'utf8'));
29
29
  const version = pkgData.version || '';
30
- if (!version.startsWith('2.')) {
31
- console.error(`\n\x1b[31m[ABORT] Blocked publishing version ${version}.\x1b[0m`);
32
- console.error('Only major v2 version package releases (version starting with "2.") are permitted.');
33
- console.log('Update the version in package.json to v2.0.0 or higher.\n');
30
+
31
+ // Semver regex pattern
32
+ const semverRegex = /^(\d+)\.(\d+)\.(\d+)(?:-([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?(?:\+([0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*))?$/;
33
+ const match = version.match(semverRegex);
34
+
35
+ if (!match) {
36
+ console.error(`\n\x1b[31m[ABORT] Blocked publishing version "${version}". Invalid semver format.\x1b[0m\n`);
37
+ process.exit(1);
38
+ }
39
+
40
+ const major = parseInt(match[1], 10);
41
+ const prerelease = match[4];
42
+
43
+ // Block versions below 2.0.0
44
+ if (major < 2) {
45
+ console.error(`\n\x1b[31m[ABORT] Blocked publishing version "${version}". Only stable major versions >=2 are permitted.\x1b[0m\n`);
46
+ process.exit(1);
47
+ }
48
+
49
+ // Block prerelease versions unless MMDO_ALLOW_PRERELEASE_PUBLISH=true
50
+ if (prerelease && process.env.MMDO_ALLOW_PRERELEASE_PUBLISH !== 'true') {
51
+ console.error(`\n\x1b[31m[ABORT] Blocked publishing prerelease version "${version}".\x1b[0m`);
52
+ console.error('To publish prereleases, you must set: MMDO_ALLOW_PRERELEASE_PUBLISH=true\n');
34
53
  process.exit(1);
35
54
  }
55
+ } else {
56
+ console.error('\n\x1b[31m[ERROR] package.json not found.\x1b[0m\n');
57
+ process.exit(1);
36
58
  }
37
59
  } catch (e) {
38
60
  console.error(`\n\x1b[31m[ERROR] Failed to read package.json version: ${e.message}\x1b[0m\n`);
package/scripts/verify.js CHANGED
@@ -527,6 +527,71 @@ try {
527
527
  fail++;
528
528
  }
529
529
 
530
+ // Verify prepublish guard behavior
531
+ try {
532
+ // Test 1: Blocks without MMDO_ALLOW_PUBLISH
533
+ try {
534
+ execSync('node scripts/prepublish-guard.js', {
535
+ cwd: projectRoot,
536
+ env: { ...process.env, MMDO_ALLOW_PUBLISH: 'false' },
537
+ stdio: 'pipe'
538
+ });
539
+ console.error(` ${RED}✗${NC} prepublish-guard should have failed without MMDO_ALLOW_PUBLISH=true`);
540
+ fail++;
541
+ } catch (err) {
542
+ const output = err.stderr ? err.stderr.toString() : '';
543
+ if (output.includes('Publishing requires explicit release approval')) {
544
+ console.log(` ${GREEN}✓${NC} prepublish guard blocks without MMDO_ALLOW_PUBLISH`);
545
+ pass++;
546
+ } else {
547
+ console.error(` ${RED}✗${NC} prepublish guard failed with unexpected error: ${output}`);
548
+ fail++;
549
+ }
550
+ }
551
+
552
+ // Test 2: Allows version 3.0.0 with MMDO_ALLOW_PUBLISH=true
553
+ try {
554
+ const output = execSync('node scripts/prepublish-guard.js', {
555
+ cwd: projectRoot,
556
+ env: { ...process.env, MMDO_ALLOW_PUBLISH: 'true' },
557
+ encoding: 'utf8'
558
+ });
559
+ if (output.includes('Prepublish guard passed')) {
560
+ console.log(` ${GREEN}✓${NC} prepublish guard allows version 3.0.0 when MMDO_ALLOW_PUBLISH=true`);
561
+ pass++;
562
+ } else {
563
+ console.error(` ${RED}✗${NC} prepublish guard passed but stdout missing success indicator`);
564
+ fail++;
565
+ }
566
+ } catch (err) {
567
+ const errText = err.stderr ? err.stderr.toString() : '';
568
+ console.error(` ${RED}✗${NC} prepublish guard blocked version 3.0.0: ${errText || err.message}`);
569
+ fail++;
570
+ }
571
+
572
+ // Test 3: Guard output no longer has "Only major v2" wording
573
+ const guardCode = readFileSync(join(projectRoot, 'scripts', 'prepublish-guard.js'), 'utf8');
574
+ if (guardCode.includes('Only major v2')) {
575
+ console.error(` ${RED}✗${NC} prepublish-guard still contains "Only major v2" wording`);
576
+ fail++;
577
+ } else {
578
+ console.log(` ${GREEN}✓${NC} prepublish guard no longer has "Only major v2" wording`);
579
+ pass++;
580
+ }
581
+
582
+ // Test 4: Package.json version is exactly 3.0.0
583
+ if (expectedVersion === '3.0.0') {
584
+ console.log(` ${GREEN}✓${NC} package.json version is exactly 3.0.0`);
585
+ pass++;
586
+ } else {
587
+ console.error(` ${RED}✗${NC} package.json version is not 3.0.0 (found ${expectedVersion})`);
588
+ fail++;
589
+ }
590
+ } catch (e) {
591
+ console.error(` ${RED}✗${NC} prepublish guard checks failed: ${e.message}`);
592
+ fail++;
593
+ }
594
+
530
595
  // --- v2.8.0 / v2.8.1 Dashboard & Plugin Tests ---
531
596
  console.log('\nRunning TUI Dashboard & Plugin Pre-Flight Tests...');
532
597