@travetto/repo 5.0.0-rc.1 → 5.0.0-rc.3
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.
package/README.md
CHANGED
|
@@ -124,7 +124,6 @@ module/auth-rest
|
|
|
124
124
|
module/auth-rest-jwt
|
|
125
125
|
module/auth-rest-passport
|
|
126
126
|
module/auth-rest-session
|
|
127
|
-
module/base
|
|
128
127
|
module/cache
|
|
129
128
|
module/cli
|
|
130
129
|
module/command
|
|
@@ -171,6 +170,7 @@ module/rest-model
|
|
|
171
170
|
module/rest-model-query
|
|
172
171
|
module/rest-session
|
|
173
172
|
module/rest-upload
|
|
173
|
+
module/runtime
|
|
174
174
|
module/scaffold
|
|
175
175
|
module/schema
|
|
176
176
|
module/schema-faker
|
|
@@ -178,7 +178,6 @@ module/terminal
|
|
|
178
178
|
module/test
|
|
179
179
|
module/transformer
|
|
180
180
|
module/worker
|
|
181
|
-
node_modules/@travetto/asset-rest
|
|
182
181
|
related/todo-app
|
|
183
182
|
```
|
|
184
183
|
|
|
@@ -206,79 +205,78 @@ The standard format includes prefixed output to help identify which module produ
|
|
|
206
205
|
$ trv repo:exec pwd
|
|
207
206
|
|
|
208
207
|
global-test/asset-rest-upload <workspace-root>/global-test/asset-rest-upload
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
module/
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
module/model-
|
|
254
|
-
module/model-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
module/rest-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
module/
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
module/worker <workspace-root>/module/worker
|
|
208
|
+
global-test/auth-rest <workspace-root>/global-test/auth-rest
|
|
209
|
+
global-test/auth-rest-jwt <workspace-root>/global-test/auth-rest-jwt
|
|
210
|
+
global-test/model_asset <workspace-root>/global-test/model_asset
|
|
211
|
+
global-test/model_auth-model <workspace-root>/global-test/model_auth-model
|
|
212
|
+
global-test/model_cache <workspace-root>/global-test/model_cache
|
|
213
|
+
global-test/model_rest-session <workspace-root>/global-test/model_rest-session
|
|
214
|
+
global-test/openapi <workspace-root>/global-test/openapi
|
|
215
|
+
global-test/pack_app <workspace-root>/global-test/pack_app
|
|
216
|
+
global-test/rest-client <workspace-root>/global-test/rest-client
|
|
217
|
+
global-test/rest-session <workspace-root>/global-test/rest-session
|
|
218
|
+
global-test/rest-upload <workspace-root>/global-test/rest-upload
|
|
219
|
+
global-test/transformer-test <workspace-root>/global-test/transformer-test
|
|
220
|
+
module/asset <workspace-root>/module/asset
|
|
221
|
+
module/auth <workspace-root>/module/auth
|
|
222
|
+
module/auth-model <workspace-root>/module/auth-model
|
|
223
|
+
module/auth-rest <workspace-root>/module/auth-rest
|
|
224
|
+
module/auth-rest-jwt <workspace-root>/module/auth-rest-jwt
|
|
225
|
+
module/auth-rest-passport <workspace-root>/module/auth-rest-passport
|
|
226
|
+
module/auth-rest-session <workspace-root>/module/auth-rest-session
|
|
227
|
+
module/cache <workspace-root>/module/cache
|
|
228
|
+
module/cli <workspace-root>/module/cli
|
|
229
|
+
module/command <workspace-root>/module/command
|
|
230
|
+
module/compiler <workspace-root>/module/compiler
|
|
231
|
+
module/config <workspace-root>/module/config
|
|
232
|
+
module/context <workspace-root>/module/context
|
|
233
|
+
module/di <workspace-root>/module/di
|
|
234
|
+
module/doc <workspace-root>/module/doc
|
|
235
|
+
module/email <workspace-root>/module/email
|
|
236
|
+
module/email-compiler <workspace-root>/module/email-compiler
|
|
237
|
+
module/email-inky <workspace-root>/module/email-inky
|
|
238
|
+
module/email-nodemailer <workspace-root>/module/email-nodemailer
|
|
239
|
+
module/eslint <workspace-root>/module/eslint
|
|
240
|
+
module/image <workspace-root>/module/image
|
|
241
|
+
module/jwt <workspace-root>/module/jwt
|
|
242
|
+
module/log <workspace-root>/module/log
|
|
243
|
+
module/manifest <workspace-root>/module/manifest
|
|
244
|
+
module/model <workspace-root>/module/model
|
|
245
|
+
module/model-dynamodb <workspace-root>/module/model-dynamodb
|
|
246
|
+
module/model-elasticsearch <workspace-root>/module/model-elasticsearch
|
|
247
|
+
module/model-firestore <workspace-root>/module/model-firestore
|
|
248
|
+
module/model-mongo <workspace-root>/module/model-mongo
|
|
249
|
+
module/model-mysql <workspace-root>/module/model-mysql
|
|
250
|
+
module/model-postgres <workspace-root>/module/model-postgres
|
|
251
|
+
module/model-query <workspace-root>/module/model-query
|
|
252
|
+
module/model-redis <workspace-root>/module/model-redis
|
|
253
|
+
module/model-s3 <workspace-root>/module/model-s3
|
|
254
|
+
module/model-sql <workspace-root>/module/model-sql
|
|
255
|
+
module/model-sqlite <workspace-root>/module/model-sqlite
|
|
256
|
+
module/openapi <workspace-root>/module/openapi
|
|
257
|
+
module/pack <workspace-root>/module/pack
|
|
258
|
+
module/registry <workspace-root>/module/registry
|
|
259
|
+
module/repo .
|
|
260
|
+
module/rest <workspace-root>/module/rest
|
|
261
|
+
module/rest-aws-lambda <workspace-root>/module/rest-aws-lambda
|
|
262
|
+
module/rest-client <workspace-root>/module/rest-client
|
|
263
|
+
module/rest-express <workspace-root>/module/rest-express
|
|
264
|
+
module/rest-express-lambda <workspace-root>/module/rest-express-lambda
|
|
265
|
+
module/rest-fastify <workspace-root>/module/rest-fastify
|
|
266
|
+
module/rest-fastify-lambda <workspace-root>/module/rest-fastify-lambda
|
|
267
|
+
module/rest-koa <workspace-root>/module/rest-koa
|
|
268
|
+
module/rest-koa-lambda <workspace-root>/module/rest-koa-lambda
|
|
269
|
+
module/rest-model <workspace-root>/module/rest-model
|
|
270
|
+
module/rest-model-query <workspace-root>/module/rest-model-query
|
|
271
|
+
module/rest-session <workspace-root>/module/rest-session
|
|
272
|
+
module/rest-upload <workspace-root>/module/rest-upload
|
|
273
|
+
module/runtime <workspace-root>/module/runtime
|
|
274
|
+
module/scaffold <workspace-root>/module/scaffold
|
|
275
|
+
module/schema <workspace-root>/module/schema
|
|
276
|
+
module/schema-faker <workspace-root>/module/schema-faker
|
|
277
|
+
module/terminal <workspace-root>/module/terminal
|
|
278
|
+
module/test <workspace-root>/module/test
|
|
279
|
+
related/todo-app <workspace-root>/related/todo-app
|
|
280
|
+
module/transformer <workspace-root>/module/transformer
|
|
281
|
+
module/worker <workspace-root>/module/worker
|
|
284
282
|
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@travetto/repo",
|
|
3
|
-
"version": "5.0.0-rc.
|
|
3
|
+
"version": "5.0.0-rc.3",
|
|
4
4
|
"description": "Monorepo utilities",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"travetto",
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
"directory": "module/repo"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@travetto/cli": "^5.0.0-rc.
|
|
26
|
-
"@travetto/worker": "^5.0.0-rc.
|
|
25
|
+
"@travetto/cli": "^5.0.0-rc.3",
|
|
26
|
+
"@travetto/worker": "^5.0.0-rc.3"
|
|
27
27
|
},
|
|
28
28
|
"peerDependenciesMeta": {
|
|
29
29
|
"@travetto/cli": {
|
package/support/bin/exec.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { ChildProcess } from 'node:child_process';
|
|
2
|
-
import rl from 'node:readline/promises';
|
|
3
2
|
|
|
4
|
-
import { ExecutionResult, Env, Util, ExecUtil } from '@travetto/
|
|
3
|
+
import { ExecutionResult, Env, Util, ExecUtil } from '@travetto/runtime';
|
|
5
4
|
import { CliModuleUtil } from '@travetto/cli';
|
|
6
5
|
import type { IndexedModule } from '@travetto/manifest';
|
|
7
6
|
import { StyleUtil, Terminal, TerminalUtil } from '@travetto/terminal';
|
|
@@ -73,12 +72,12 @@ export class RepoExecUtil {
|
|
|
73
72
|
processes.set(mod, proc);
|
|
74
73
|
|
|
75
74
|
if (config.showStdout && proc.stdout) {
|
|
76
|
-
|
|
75
|
+
ExecUtil.readLines(proc.stdout, line =>
|
|
77
76
|
stdoutTerm.writer.writeLine(`${prefix}${line.trimEnd()}`).commit()
|
|
78
77
|
);
|
|
79
78
|
}
|
|
80
79
|
if (config.showStderr && proc.stderr) {
|
|
81
|
-
|
|
80
|
+
ExecUtil.readLines(proc.stderr, line =>
|
|
82
81
|
stderrTerm.writer.writeLine(`${prefix}${line.trimEnd()}`).commit()
|
|
83
82
|
);
|
|
84
83
|
}
|
|
@@ -2,7 +2,7 @@ import path from 'node:path';
|
|
|
2
2
|
import { spawn, ChildProcess } from 'node:child_process';
|
|
3
3
|
import fs from 'node:fs/promises';
|
|
4
4
|
|
|
5
|
-
import { ExecUtil, ExecutionResult } from '@travetto/
|
|
5
|
+
import { ExecUtil, ExecutionResult } from '@travetto/runtime';
|
|
6
6
|
import { type IndexedModule, type ManifestContext, type Package, PackageUtil } from '@travetto/manifest';
|
|
7
7
|
import { CliModuleUtil } from '@travetto/cli';
|
|
8
8
|
|
package/support/cli.repo_exec.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { spawn } from 'node:child_process';
|
|
|
2
2
|
|
|
3
3
|
import { CliCommand, CliCommandShape, ParsedState } from '@travetto/cli';
|
|
4
4
|
import { WorkPool } from '@travetto/worker';
|
|
5
|
-
import { Env } from '@travetto/
|
|
5
|
+
import { Env } from '@travetto/runtime';
|
|
6
6
|
import { Ignore, Max, Min } from '@travetto/schema';
|
|
7
7
|
|
|
8
8
|
import { RepoExecUtil } from './bin/exec';
|
package/support/cli.repo_list.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { CliCommandShape, CliCommand, CliModuleUtil } from '@travetto/cli';
|
|
2
|
-
import { RuntimeIndex } from '@travetto/
|
|
3
|
-
import { RuntimeContext } from '@travetto/base';
|
|
2
|
+
import { Runtime, RuntimeIndex } from '@travetto/runtime';
|
|
4
3
|
|
|
5
4
|
const write = (line: string): Promise<void> => new Promise(r => process.stdout.write(`${line}\n`, () => r()));
|
|
6
5
|
|
|
@@ -48,7 +47,7 @@ export class ListModuleCommand implements CliCommandShape {
|
|
|
48
47
|
await write('digraph g {');
|
|
49
48
|
for (const el of mods) {
|
|
50
49
|
for (const dep of el.parents) {
|
|
51
|
-
if (dep !==
|
|
50
|
+
if (dep !== Runtime.main.name) {
|
|
52
51
|
await write(` "${dep}" -> "${el.name}";`);
|
|
53
52
|
}
|
|
54
53
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CliCommandShape, CliCommand } from '@travetto/cli';
|
|
2
|
-
import {
|
|
2
|
+
import { Runtime } from '@travetto/runtime';
|
|
3
3
|
|
|
4
4
|
import { PackageManager } from './bin/package-manager';
|
|
5
5
|
import { RepoExecUtil } from './bin/exec';
|
|
@@ -14,11 +14,11 @@ export class RepoPublishCommand implements CliCommandShape {
|
|
|
14
14
|
dryRun = true;
|
|
15
15
|
|
|
16
16
|
async main(): Promise<void> {
|
|
17
|
-
const published = await RepoExecUtil.execOnModules('all', mod => PackageManager.isPublished(
|
|
17
|
+
const published = await RepoExecUtil.execOnModules('all', mod => PackageManager.isPublished(Runtime, mod), {
|
|
18
18
|
filter: mod => !!mod.workspace && !mod.internal,
|
|
19
19
|
progressMessage: (mod) => `Checking published [%idx/%total] -- ${mod?.name}`,
|
|
20
20
|
showStderr: false,
|
|
21
|
-
transformResult: (mod, res) => PackageManager.validatePublishedResult(
|
|
21
|
+
transformResult: (mod, res) => PackageManager.validatePublishedResult(Runtime, mod, res),
|
|
22
22
|
});
|
|
23
23
|
|
|
24
24
|
if (this.dryRun) {
|
|
@@ -26,7 +26,7 @@ export class RepoPublishCommand implements CliCommandShape {
|
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
await RepoExecUtil.execOnModules(
|
|
29
|
-
'all', mod => PackageManager.publish(
|
|
29
|
+
'all', mod => PackageManager.publish(Runtime, mod, this.dryRun),
|
|
30
30
|
{
|
|
31
31
|
progressMessage: (mod) => `Published [%idx/%total] -- ${mod?.name}`,
|
|
32
32
|
showStdout: false,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import fs from 'node:fs/promises';
|
|
2
2
|
|
|
3
3
|
import { CliModuleUtil, CliCommandShape, CliCommand, CliScmUtil, CliValidationError } from '@travetto/cli';
|
|
4
|
-
import {
|
|
4
|
+
import { Runtime } from '@travetto/runtime';
|
|
5
5
|
|
|
6
6
|
import { PackageManager, SemverLevel } from './bin/package-manager';
|
|
7
7
|
|
|
@@ -46,7 +46,7 @@ export class RepoVersionCommand implements CliCommandShape {
|
|
|
46
46
|
throw new Error('No modules available for versioning');
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
await PackageManager.version(
|
|
49
|
+
await PackageManager.version(Runtime, modules, level, prefix);
|
|
50
50
|
|
|
51
51
|
const versions = await PackageManager.synchronizeVersions();
|
|
52
52
|
if (this.commit) {
|
|
@@ -57,7 +57,7 @@ export class RepoVersionCommand implements CliCommandShape {
|
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
// Touch package when done to trigger restart of compiler
|
|
60
|
-
await fs.utimes(
|
|
60
|
+
await fs.utimes(Runtime.workspaceRelative('package.json'), Date.now(), Date.now());
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
63
|
}
|