@ms-cloudpack/api-server 0.54.1 → 0.54.2
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/lib/common/createPartialApiContext.d.ts.map +1 -1
- package/lib/common/createPartialApiContext.js.map +1 -1
- package/lib/types/Context.d.ts +2 -3
- package/lib/types/Context.d.ts.map +1 -1
- package/lib/types/Context.js.map +1 -1
- package/lib/utilities/getBundleLocation.d.ts +2 -3
- package/lib/utilities/getBundleLocation.d.ts.map +1 -1
- package/lib/utilities/getBundleLocation.js.map +1 -1
- package/package.json +10 -10
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createPartialApiContext.d.ts","sourceRoot":"","sources":["../../src/common/createPartialApiContext.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;
|
|
1
|
+
{"version":3,"file":"createPartialApiContext.d.ts","sourceRoot":"","sources":["../../src/common/createPartialApiContext.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAE7D,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAM/D,MAAM,WAAW,qBAAsB,SAAQ,oBAAoB;IACjE,QAAQ,EAAE,YAAY,CAAC;IACvB,OAAO,EAAE,MAAM,CAAC;IAChB,eAAe,EAAE,eAAe,CAAC;IACjC,UAAU,CAAC,EAAE,UAAU,CAAC;CACzB;AA+HD,wBAAsB,uBAAuB,CAC3C,KAAK,SAAS,OAAO,CAAC,MAAM,OAAO,EAAE,SAAS,CAAC,EAC/C,OAAO,SAAS,IAAI,CAAC,OAAO,EAAE,KAAK,GAAG,SAAS,GAAG,UAAU,GAAG,iBAAiB,CAAC,EACjF,OAAO,EAAE,qBAAqB,GAAG;IAAE,KAAK,EAAE,KAAK,EAAE,CAAA;CAAE,GAAG,OAAO,CAAC,OAAO,CAAC,CAiBvE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createPartialApiContext.js","sourceRoot":"","sources":["../../src/common/createPartialApiContext.ts"],"names":[],"mappings":";;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"createPartialApiContext.js","sourceRoot":"","sources":["../../src/common/createPartialApiContext.ts"],"names":[],"mappings":";;;;;;;;;;;;AAqBA,MAAM,cAAc;IASlB,YAA6B,OAA8B;QAA9B,YAAO,GAAP,OAAO,CAAuB;QAR3D,sCAAmC;QACnC,0CAAuC;QACvC,2CAAwD;QACxD,6CAA6C;QAC7C,0CAAuC;QACvC,qDAA6D;QAC7D,gDAAwD;QAGtD,MAAM,EAAE,UAAU,EAAE,GAAG,OAAO,CAAC;QAC/B,IAAI,UAAU,EAAE,CAAC;YACf,uBAAA,IAAI,8BAAe,OAAO,CAAC,OAAO,CAAC,UAAU,CAAC,MAAA,CAAC;QACjD,CAAC;IACH,CAAC;IAED,IAAW,eAAe;QACxB,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;IACvD,CAAC;IAED,IAAW,GAAG;QACZ,IAAI,CAAC,uBAAA,IAAI,2BAAK,EAAE,CAAC;YACf,MAAM,iBAAiB,GAAG,KAAK,IAAI,EAAE;gBACnC,MAAM,EAAE,aAAa,EAAE,GAAG,MAAM,MAAM,CAAC,wBAAwB,CAAC,CAAC;gBACjE,OAAO,aAAa,E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Q;oBAC7B,eAAe,EAAE,MAAM,IAAI,CAAC,eAAe;iBAC5C,CAAC,CAAC;YACL,CAAC,CAAC;YACF,uBAAA,IAAI,2BAAY,iBAAiB,EAAE,MAAA,CAAC;QACtC,CAAC;QAED,OAAO,uBAAA,IAAI,+BAAS,CAAC;IACvB,CAAC;IAED,IAAW,kBAAkB;QAC3B,IAAI,CAAC,uBAAA,IAAI,0CAAoB,EAAE,CAAC;YAC9B,uBAAA,IAAI,sCAAuB,OAAO,CAAC,OAAO,CAAC,IAAI,GAAG,EAAoB,CAAC,MAAA,CAAC;QAC1E,CAAC;QACD,OAAO,uBAAA,IAAI,0CAAoB,CAAC;IAClC,CAAC;IAEM,KAAK,CAAC,OAAO;QAClB,IAAI,uBAAA,IAAI,+BAAS,EAAE,CAAC;YAClB,MAAM,OAAO,GAAG,MAAM,uBAAA,IAAI,+BAAS,CAAC;YACpC,MAAM,OAAO,CAAC,UAAU,EAAE,CAAC;QAC7B,CAAC;IACH,CAAC;CACF;;AAED,MAAM,CAAC,KAAK,UAAU,uBAAuB,CAG3C,OAAmD;IACnD,MAAM,EAAE,QAAQ,EAAE,eAAe,EAAE,KAAK,EAAE,GAAG,OAAO,CAAC;IACrD,MAAM,WAAW,GAAG,IAAI,cAAc,CAAC,OAAO,CAAC,CAAC;IAEhD,MAAM,MAAM,GAAG;QACb,QAAQ;QACR,eAAe;QACf,OAAO,EAAE,GAAG,EAAE;YACZ,OAAO,WAAW,CAAC,OAAO,EAAE,CAAC;QAC/B,CAAC;KACS,CAAC;IAEb,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,CAAC;QACzB,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,MAAM,WAAW,CAAC,IAAI,CAAC,CAAmB,CAAC;IAC7D,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC","sourcesContent":["import type { PackageDefinitionsCache, PackageHashesCache, Session } from '@ms-cloudpack/common-types';\nimport type { DataBus } from '@ms-cloudpack/data-bus';\nimport type { Watcher } from '@ms-cloudpack/file-watcher';\nimport type { TaskReporter } from '@ms-cloudpack/task-reporter';\nimport type { TelemetryClient } from '@ms-cloudpack/telemetry';\nimport type { Context } from '../types/Context.js';\nimport type { TaskRunner } from '../utilities/TaskRunner.js';\nimport type { PackageImportPaths } from '@ms-cloudpack/import-map';\nimport type { CreateSessionOptions } from './createSession.js';\n\ntype PromisifyProperties<T> = {\n [K in keyof T]: T[K] extends (...args: unknown[]) => unknown ? T[K] : Promise<T[K]>;\n};\n\nexport interface LazyApiContextOptions extends CreateSessionOptions {\n reporter: TaskReporter;\n appPath: string;\n telemetryClient: TelemetryClient;\n taskRunner?: TaskRunner;\n}\n\nclass LazyApiContext implements PromisifyProperties<Context> {\n #bus: Promise<DataBus> | undefined;\n #watcher: Promise<Watcher> | undefined;\n #packages: Promise<PackageDefinitionsCache> | undefined;\n #taskRunner: Promise<TaskRunner> | undefined;\n #session: Promise<Session> | undefined;\n #packageImportPaths: Promise<PackageImportPaths> | undefined;\n #packageHashes: Promise<PackageHashesCache> | undefined;\n\n constructor(private readonly options: LazyApiContextOptions) {\n const { taskRunner } = options;\n if (taskRunner) {\n this.#taskRunner = Promise.resolve(taskRunner);\n }\n }\n\n public get telemetryClient(): Promise<TelemetryClient> {\n return Promise.resolve(this.options.telemetryClient);\n }\n\n public get bus(): Promise<DataBus> {\n if (!this.#bus) {\n const createDataBusLazy = async () => {\n const { createDataBus } = await import('@ms-cloudpack/data-bus');\n return createDataBus();\n };\n this.#bus = createDataBusLazy();\n }\n\n return this.#bus;\n }\n\n public get watcher(): Promise<Watcher> {\n if (!this.#watcher) {\n const createWatcherLazy = async () => {\n const { createWatcher } = await import('@ms-cloudpack/file-watcher');\n return createWatcher();\n };\n this.#watcher = createWatcherLazy();\n }\n\n return this.#watcher;\n }\n\n public get reporter(): Promise<TaskReporter> {\n return Promise.resolve(this.options.reporter);\n }\n\n public get packages(): Promise<PackageDefinitionsCache> {\n if (!this.#packages) {\n const createPackageDefinitionsLazy = async () => {\n const { createPackageDefinitions } = await import('@ms-cloudpack/config');\n return createPackageDefinitions({ config: this.options.config });\n };\n this.#packages = createPackageDefinitionsLazy();\n }\n\n return this.#packages;\n }\n\n public get packageHashes(): Promise<PackageHashesCache> {\n if (!this.#packageHashes) {\n const createPackageHashesLazy = async () => {\n const { PackageHashes } = await import('@ms-cloudpack/package-hashes');\n return new PackageHashes({\n cwd: this.options.appPath,\n context: {\n config: this.options.config,\n packages: await this.packages,\n resolveMap: (await this.session).resolveMap,\n },\n });\n };\n this.#packageHashes = createPackageHashesLazy();\n }\n\n return this.#packageHashes;\n }\n\n public get taskRunner(): Promise<TaskRunner> {\n if (!this.#taskRunner) {\n const createTaskRunnerLazy = async () => {\n const { TaskRunner } = await import('../utilities/TaskRunner.js');\n return new TaskRunner({\n bus: await this.bus,\n reporter: await this.reporter,\n session: await this.session,\n });\n };\n this.#taskRunner = createTaskRunnerLazy();\n }\n return this.#taskRunner;\n }\n\n public get session(): Promise<Session> {\n if (!this.#session) {\n const createSessionLazy = async () => {\n const { createSession } = await import('./createSession.js');\n return createSession(this.options, {\n reporter: await this.reporter,\n packages: await this.packages,\n telemetryClient: await this.telemetryClient,\n });\n };\n this.#session = createSessionLazy();\n }\n\n return this.#session;\n }\n\n public get packageImportPaths(): Promise<PackageImportPaths> {\n if (!this.#packageImportPaths) {\n this.#packageImportPaths = Promise.resolve(new Map<string, string[]>());\n }\n return this.#packageImportPaths;\n }\n\n public async dispose() {\n if (this.#watcher) {\n const watcher = await this.#watcher;\n await watcher.unwatchAll();\n }\n }\n}\n\nexport async function createPartialApiContext<\n TKeys extends Exclude<keyof Context, 'dispose'>,\n TReturn extends Pick<Context, TKeys | 'dispose' | 'reporter' | 'telemetryClient'>,\n>(options: LazyApiContextOptions & { items: TKeys[] }): Promise<TReturn> {\n const { reporter, telemetryClient, items } = options;\n const lazyContext = new LazyApiContext(options);\n\n const result = {\n reporter,\n telemetryClient,\n dispose: () => {\n return lazyContext.dispose();\n },\n } as TReturn;\n\n for (const item of items) {\n result[item] = (await lazyContext[item]) as TReturn[TKeys];\n }\n\n return result;\n}\n"]}
|
package/lib/types/Context.d.ts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import type { PackageDefinitionsCache, Session } from '@ms-cloudpack/common-types';
|
|
1
|
+
import type { PackageDefinitionsCache, PackageHashesCache, Session } from '@ms-cloudpack/common-types';
|
|
2
2
|
import type { DataBus } from '@ms-cloudpack/data-bus';
|
|
3
3
|
import type { Watcher } from '@ms-cloudpack/file-watcher';
|
|
4
4
|
import type { TaskReporter } from '@ms-cloudpack/task-reporter';
|
|
5
5
|
import type { TelemetryClient } from '@ms-cloudpack/telemetry';
|
|
6
6
|
import type { TaskRunner } from '../utilities/TaskRunner.js';
|
|
7
|
-
import type { PackageHashes } from '@ms-cloudpack/package-hashes';
|
|
8
7
|
import type { PackageImportPaths } from '@ms-cloudpack/import-map';
|
|
9
8
|
/** Context for Cloudpack API server procedures. */
|
|
10
9
|
export interface Context {
|
|
@@ -16,7 +15,7 @@ export interface Context {
|
|
|
16
15
|
packages: PackageDefinitionsCache;
|
|
17
16
|
taskRunner: TaskRunner;
|
|
18
17
|
packageImportPaths: PackageImportPaths;
|
|
19
|
-
packageHashes:
|
|
18
|
+
packageHashes: PackageHashesCache;
|
|
20
19
|
dispose(): Promise<void>;
|
|
21
20
|
}
|
|
22
21
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../../src/types/Context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;
|
|
1
|
+
{"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../../src/types/Context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,kBAAkB,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;AACvG,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAC7D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAEnE,mDAAmD;AACnD,MAAM,WAAW,OAAO;IACtB,OAAO,EAAE,OAAO,CAAC;IACjB,GAAG,EAAE,OAAO,CAAC;IACb,eAAe,EAAE,eAAe,CAAC;IACjC,QAAQ,EAAE,YAAY,CAAC;IACvB,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,uBAAuB,CAAC;IAClC,UAAU,EAAE,UAAU,CAAC;IACvB,kBAAkB,EAAE,kBAAkB,CAAC;IACvC,aAAa,EAAE,kBAAkB,CAAC;IAClC,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CAC1B;AAED;;;;GAIG;AACH,MAAM,MAAM,cAAc,CACxB,YAAY,SAAS,MAAM,IAAI,CAAC,OAAO,EAAE,SAAS,CAAC,EACnD,YAAY,SAAS,MAAM,OAAO,IAChC,IAAI,CAAC,OAAO,EAAE,YAAY,CAAC,GAAG;IAChC,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,YAAY,CAAC,CAAC;CACtC,CAAC"}
|
package/lib/types/Context.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Context.js","sourceRoot":"","sources":["../../src/types/Context.ts"],"names":[],"mappings":"","sourcesContent":["import type { PackageDefinitionsCache, Session } from '@ms-cloudpack/common-types';\nimport type { DataBus } from '@ms-cloudpack/data-bus';\nimport type { Watcher } from '@ms-cloudpack/file-watcher';\nimport type { TaskReporter } from '@ms-cloudpack/task-reporter';\nimport type { TelemetryClient } from '@ms-cloudpack/telemetry';\nimport type { TaskRunner } from '../utilities/TaskRunner.js';\nimport type {
|
|
1
|
+
{"version":3,"file":"Context.js","sourceRoot":"","sources":["../../src/types/Context.ts"],"names":[],"mappings":"","sourcesContent":["import type { PackageDefinitionsCache, PackageHashesCache, Session } from '@ms-cloudpack/common-types';\nimport type { DataBus } from '@ms-cloudpack/data-bus';\nimport type { Watcher } from '@ms-cloudpack/file-watcher';\nimport type { TaskReporter } from '@ms-cloudpack/task-reporter';\nimport type { TelemetryClient } from '@ms-cloudpack/telemetry';\nimport type { TaskRunner } from '../utilities/TaskRunner.js';\nimport type { PackageImportPaths } from '@ms-cloudpack/import-map';\n\n/** Context for Cloudpack API server procedures. */\nexport interface Context {\n session: Session;\n bus: DataBus;\n telemetryClient: TelemetryClient;\n reporter: TaskReporter;\n watcher: Watcher;\n packages: PackageDefinitionsCache;\n taskRunner: TaskRunner;\n packageImportPaths: PackageImportPaths;\n packageHashes: PackageHashesCache;\n dispose(): Promise<void>;\n}\n\n/**\n * Helper for partial context and session objects.\n * First param is context keys and second is session keys.\n * (This can make it easier to tell which properties are actually used where.)\n */\nexport type PartialContext<\n TContextKeys extends keyof Omit<Context, 'session'>,\n TSessionKeys extends keyof Session,\n> = Pick<Context, TContextKeys> & {\n session: Pick<Session, TSessionKeys>;\n};\n"]}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
+
import type { PackageHashOptions } from '@ms-cloudpack/common-types';
|
|
1
2
|
import type { PartialContext } from '../types/Context.js';
|
|
2
|
-
export declare function getBundleLocation(options: {
|
|
3
|
-
packagePath: string;
|
|
4
|
-
shouldRecalculate?: boolean;
|
|
3
|
+
export declare function getBundleLocation(options: Omit<PackageHashOptions, 'isSourceHashingEnabled'> & {
|
|
5
4
|
hash?: string;
|
|
6
5
|
}, context: PartialContext<'packages' | 'packageHashes', 'cachePath'>): Promise<{
|
|
7
6
|
path: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getBundleLocation.d.ts","sourceRoot":"","sources":["../../src/utilities/getBundleLocation.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getBundleLocation.d.ts","sourceRoot":"","sources":["../../src/utilities/getBundleLocation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAGrE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AAE1D,wBAAsB,iBAAiB,CACrC,OAAO,EAAE,IAAI,CAAC,kBAAkB,EAAE,wBAAwB,CAAC,GAAG;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,EAC/E,OAAO,EAAE,cAAc,CAAC,UAAU,GAAG,eAAe,EAAE,WAAW,CAAC;;;GA4BnE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getBundleLocation.js","sourceRoot":"","sources":["../../src/utilities/getBundleLocation.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"getBundleLocation.js","sourceRoot":"","sources":["../../src/utilities/getBundleLocation.ts"],"names":[],"mappings":"AACA,OAAO,UAAU,MAAM,YAAY,CAAC;AACpC,OAAO,IAAI,MAAM,MAAM,CAAC;AAGxB,MAAM,CAAC,KAAK,UAAU,iBAAiB,CACrC,OAA+E,EAC/E,OAAkE;IAElE,MAAM,EAAE,WAAW,EAAE,iBAAiB,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC;IACzD,MAAM,EAAE,QAAQ,EAAE,aAAa,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC;IACrD,MAAM,EAAE,SAAS,EAAE,GAAG,OAAO,CAAC;IAC9B,MAAM,UAAU,GAAG,MAAM,QAAQ,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC;IAEnD,MAAM,EAAE,IAAI,EAAE,OAAO,EAAE,GAAG,UAAU,CAAC;IAErC,MAAM,UAAU,GACd,IAAI;QACJ,CAAC,MAAM,aAAa,CAAC,GAAG,CAAC;YACvB,WAAW;YACX;;;eAGG;YACH,sBAAsB,EAAE,KAAK;YAC7B,iBAAiB;SAClB,CAAC,CAAC,CAAC;IACN,qCAAqC;IACrC,MAAM,UAAU,GAAG,GAAG,UAAU,CAAC,IAAI,EAAE,EAAE,WAAW,EAAE,GAAG,EAAE,CAAC,IAAI,OAAO,IAAI,UAAU,EAAE,CAAC;IACxF,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,UAAU,CAAC,CAAC;IAEpD,OAAO;QACL,IAAI,EAAE,UAAU;QAChB,UAAU;KACX,CAAC;AACJ,CAAC","sourcesContent":["import type { PackageHashOptions } from '@ms-cloudpack/common-types';\nimport filenamify from 'filenamify';\nimport path from 'path';\nimport type { PartialContext } from '../types/Context.js';\n\nexport async function getBundleLocation(\n options: Omit<PackageHashOptions, 'isSourceHashingEnabled'> & { hash?: string },\n context: PartialContext<'packages' | 'packageHashes', 'cachePath'>,\n) {\n const { packagePath, shouldRecalculate, hash } = options;\n const { packages, packageHashes, session } = context;\n const { cachePath } = session;\n const definition = await packages.get(packagePath);\n\n const { name, version } = definition;\n\n const hashResult =\n hash ||\n (await packageHashes.get({\n packagePath,\n /**\n * We don't use source hashing for location,\n * because we do not want to create a new folder for each change in a package.\n */\n isSourceHashingEnabled: false,\n shouldRecalculate,\n }));\n // Derive where the output should be.\n const folderName = `${filenamify(name, { replacement: '^' })}-${version}-${hashResult}`;\n const outputPath = path.join(cachePath, folderName);\n\n return {\n path: outputPath,\n folderName,\n };\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ms-cloudpack/api-server",
|
|
3
|
-
"version": "0.54.
|
|
3
|
+
"version": "0.54.2",
|
|
4
4
|
"description": "An implementation of the API server that does interacts with a task scheduler.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -27,19 +27,19 @@
|
|
|
27
27
|
"@lage-run/logger": "^1.3.0",
|
|
28
28
|
"@lage-run/scheduler": "^1.2.1",
|
|
29
29
|
"@lage-run/target-graph": "^0.8.9",
|
|
30
|
-
"@ms-cloudpack/bundler": "^0.23.
|
|
31
|
-
"@ms-cloudpack/common-types": "^0.21.
|
|
32
|
-
"@ms-cloudpack/config": "^0.31.
|
|
33
|
-
"@ms-cloudpack/create-express-app": "^1.9.
|
|
30
|
+
"@ms-cloudpack/bundler": "^0.23.3",
|
|
31
|
+
"@ms-cloudpack/common-types": "^0.21.1",
|
|
32
|
+
"@ms-cloudpack/config": "^0.31.2",
|
|
33
|
+
"@ms-cloudpack/create-express-app": "^1.9.3",
|
|
34
34
|
"@ms-cloudpack/data-bus": "^0.4.2",
|
|
35
35
|
"@ms-cloudpack/file-watcher": "^0.1.2",
|
|
36
|
-
"@ms-cloudpack/import-map": "^0.8.
|
|
36
|
+
"@ms-cloudpack/import-map": "^0.8.4",
|
|
37
37
|
"@ms-cloudpack/json-utilities": "^0.1.7",
|
|
38
|
-
"@ms-cloudpack/package-hashes": "^0.
|
|
39
|
-
"@ms-cloudpack/package-utilities": "^10.2.
|
|
38
|
+
"@ms-cloudpack/package-hashes": "^0.7.0",
|
|
39
|
+
"@ms-cloudpack/package-utilities": "^10.2.2",
|
|
40
40
|
"@ms-cloudpack/path-string-parsing": "^1.2.4",
|
|
41
|
-
"@ms-cloudpack/path-utilities": "^2.7.
|
|
42
|
-
"@ms-cloudpack/remote-cache": "^0.8.
|
|
41
|
+
"@ms-cloudpack/path-utilities": "^2.7.47",
|
|
42
|
+
"@ms-cloudpack/remote-cache": "^0.8.14",
|
|
43
43
|
"@ms-cloudpack/task-reporter": "^0.14.5",
|
|
44
44
|
"@ms-cloudpack/telemetry": "^0.6.3",
|
|
45
45
|
"@trpc/client": "^10.45.0",
|