@ms-cloudpack/cli 0.38.6 → 0.38.8
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/index.d.ts.map +1 -1
- package/lib/index.js +3 -0
- package/lib/index.js.map +1 -1
- package/package.json +5 -5
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAmBA;;;GAGG;AACH,wBAAsB,IAAI,kBAuEzB;AAED,YAAY,EACV,SAAS,EACT,SAAS,EACT,YAAY,EACZ,IAAI,EACJ,eAAe,EACf,kBAAkB,EAClB,SAAS,EACT,WAAW,EACX,oBAAoB,GACrB,MAAM,0BAA0B,CAAC;AAClC,YAAY,EAAE,eAAe,EAAE,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACpF,YAAY,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAC9D,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAC5D,YAAY,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACtE,YAAY,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AACxE,YAAY,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACtE,YAAY,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AACpE,YAAY,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AACpE,YAAY,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC"}
|
package/lib/index.js
CHANGED
|
@@ -7,6 +7,7 @@ import { fileURLToPath, pathToFileURL } from 'url';
|
|
|
7
7
|
import { initTelemetry, setSharedTelemetryAttributes } from './initTelemetry.js';
|
|
8
8
|
import { PerfMarkerCliEntry } from './performance/markers.js';
|
|
9
9
|
import { setReporterOptions } from './reporter.js';
|
|
10
|
+
import { readConfig } from '@ms-cloudpack/config';
|
|
10
11
|
const currentPath = path.dirname(fileURLToPath(import.meta.url));
|
|
11
12
|
/**
|
|
12
13
|
* Entry point for the cloudpack CLI. Resolves all commands defined
|
|
@@ -27,10 +28,12 @@ export async function main() {
|
|
|
27
28
|
const verb = process.argv[2];
|
|
28
29
|
const useVerboseLogging = process.argv.includes('--verbose') || process.argv.includes('-v') || verb === 'bundle';
|
|
29
30
|
program.name(productName).version(version).usage('<command> [options]');
|
|
31
|
+
const config = await readConfig();
|
|
30
32
|
setReporterOptions({
|
|
31
33
|
productName,
|
|
32
34
|
version,
|
|
33
35
|
description: `Running "${bold(process.argv.slice(2).join(' '))}"`,
|
|
36
|
+
helpMessage: config.helpMessage,
|
|
34
37
|
...defaultLoggingConfig,
|
|
35
38
|
...(useVerboseLogging && verboseLoggingConfig),
|
|
36
39
|
...(useDebugLogging && debugLoggingConfig),
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AACjF,OAAO,EACL,IAAI,EACJ,kBAAkB,EAClB,oBAAoB,EACpB,QAAQ,EACR,oBAAoB,GACrB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,IAAI,MAAM,MAAM,CAAC;AACxB,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,KAAK,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,4BAA4B,EAAE,MAAM,oBAAoB,CAAC;AACjF,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,eA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AAC;QAC3B,IAAI;QACJ,SAAS,EAAE,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC;QAC1C,WAAW,EAAE,OAAO,CAAC,GAAG,CAAC,EAAE,IAAI,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO;QACpE,OAAO,EAAE,UAAU,CAAC,IAAI,IAAI,UAAU;KACvC,CAAC,CAAC;IAEH,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,qBAAqB,EAAE,EAAE,GAAG,EAAE,WAAW,EAAE,CAAC,CAAC;IAExE,KAAK,MAAM,WAAW,IAAI,QAAQ,EAAE;QAClC,MAAM,OAAO,GAAG,CAAC,MAAM,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,WAAW,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAE9F,CAAC;QAEF,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;KACvB;IAED,OAAO,CAAC,MAAM,CAAC,eAAe,EAAE,mEAAmE,CAAC,CAAC;IACrG,OAAO,CAAC,MAAM,CAAC,aAAa,EAAE,kEAAkE,CAAC,CAAC;IAClG,OAAO,CAAC,MAAM,CAAC,gBAAgB,EAAE,gDAAgD,CAAC,CAAC;IAEnF,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;IAE5B,IAAI,OAAO,CAAC,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE;QAC7B,OAAO,CAAC,IAAI,EAAE,CAAC;KAChB;AACH,CAAC","sourcesContent":["import { PackageDefinitions, getVersion } from '@ms-cloudpack/package-utilities';\nimport {\n bold,\n debugLoggingConfig,\n defaultLoggingConfig,\n gradient,\n verboseLoggingConfig,\n} from '@ms-cloudpack/task-reporter';\nimport { Command } from 'commander';\nimport glob from 'glob';\nimport path from 'path';\nimport { fileURLToPath, pathToFileURL } from 'url';\nimport { initTelemetry, setSharedTelemetryAttributes } from './initTelemetry.js';\nimport { PerfMarkerCliEntry } from './performance/markers.js';\nimport { setReporterOptions } from './reporter.js';\nimport { readConfig } from '@ms-cloudpack/config';\n\nconst currentPath = path.dirname(fileURLToPath(import.meta.url));\n\n/**\n * Entry point for the cloudpack CLI. Resolves all commands defined\n * within the \"./commands\" folder.\n */\nexport async function main() {\n performance.mark(PerfMarkerCliEntry);\n\n const program = new Command();\n const plainTextMode = process.argv.includes('--no-color') || process.argv.includes('-n');\n\n // Initialize the color setting as soon as possible.\n setReporterOptions({\n plainTextMode,\n });\n\n const version = getVersion(import.meta.url);\n // the name \"Cloudpack\" preceed by an emoji representing sun behind cloud\n const productName = gradient(`Cloudpack`);\n const useDebugLogging = process.argv.includes('--debug') || process.argv.includes('-d');\n const verb = process.argv[2];\n const useVerboseLogging = process.argv.includes('--verbose') || process.argv.includes('-v') || verb === 'bundle';\n\n program.name(productName).version(version).usage('<command> [options]');\n\n const config = await readConfig();\n\n setReporterOptions({\n productName,\n version,\n description: `Running \"${bold(process.argv.slice(2).join(' '))}\"`,\n helpMessage: config.helpMessage,\n ...defaultLoggingConfig,\n ...(useVerboseLogging && verboseLoggingConfig),\n ...(useDebugLogging && debugLoggingConfig),\n });\n\n await initTelemetry({\n useDebugLogging,\n useVerboseLogging,\n });\n\n // Make sure the package has a valid definition.\n const appPath = process.cwd();\n const definition = await PackageDefinitions.getInstance().get(appPath);\n\n if (!definition) {\n throw new Error(`There was no package.json located at \"${appPath}\".`);\n }\n\n setSharedTelemetryAttributes({\n verb,\n arguments: process.argv.slice(3).join(' '),\n environment: process.env.CI || process.env.TF_BUILD ? 'ci' : 'local',\n appName: definition.name || '<unkown>',\n });\n\n const commands = glob.sync('commands/*/index.js', { cwd: currentPath });\n\n for (const commandPath of commands) {\n const command = (await import(pathToFileURL(path.resolve(currentPath, commandPath)).toString())) as {\n init: (cmd: Command) => void;\n };\n\n command.init(program);\n }\n\n program.option('-v, --verbose', 'Show additional details about the running tasks. (default: false)');\n program.option('-d, --debug', 'Show debug information (superset of --verbose). (default: false)');\n program.option('-n, --no-color', 'Disable colors in the output. (default: false)');\n\n program.parse(process.argv);\n\n if (program.args.length === 0) {\n program.help();\n }\n}\n\nexport type {\n ApiServer,\n DevServer,\n SessionStats,\n Task,\n TaskDescription,\n TaskEndDescription,\n TaskError,\n TaskOptions,\n TaskStartDescription,\n} from '@ms-cloudpack/api-server';\nexport type { CloudpackConfig, Route, TelemetryConfig } from '@ms-cloudpack/config';\nexport type { BundleRequest } from './types/BundleRequest.js';\nexport type { BundleServer } from './types/BundleServer.js';\nexport type { BundleTaskOptions } from './types/BundleTaskOptions.js';\nexport type { CreateHtmlFunction } from './types/CreateHtmlFunction.js';\nexport type { CreateHtmlOptions } from './types/CreateHtmlOptions.js';\nexport type { CreateHtmlResult } from './types/CreateHtmlResult.js';\nexport type { CreateHtmlScript } from './types/CreateHtmlScript.js';\nexport type { Watcher } from './types/Watcher.js';\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ms-cloudpack/cli",
|
|
3
|
-
"version": "0.38.
|
|
3
|
+
"version": "0.38.8",
|
|
4
4
|
"description": "The Cloudpack command line interface - a tool for managing fast inner and outer looping in web apps.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -16,9 +16,9 @@
|
|
|
16
16
|
"cloudpack": "./bin/cloudpack.js"
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@ms-cloudpack/api-server": "^0.6.
|
|
20
|
-
"@ms-cloudpack/bundler": "^0.11.
|
|
21
|
-
"@ms-cloudpack/config": "^0.
|
|
19
|
+
"@ms-cloudpack/api-server": "^0.6.6",
|
|
20
|
+
"@ms-cloudpack/bundler": "^0.11.46",
|
|
21
|
+
"@ms-cloudpack/config": "^0.7.0",
|
|
22
22
|
"@ms-cloudpack/create-express-app": "^1.3.5",
|
|
23
23
|
"@ms-cloudpack/data-bus": "^0.2.1",
|
|
24
24
|
"@ms-cloudpack/json-utilities": "^0.0.6",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"@ms-cloudpack/package-utilities": "^3.1.1",
|
|
27
27
|
"@ms-cloudpack/path-string-parsing": "^1.0.1",
|
|
28
28
|
"@ms-cloudpack/path-utilities": "^2.2.2",
|
|
29
|
-
"@ms-cloudpack/task-reporter": "^0.
|
|
29
|
+
"@ms-cloudpack/task-reporter": "^0.4.0",
|
|
30
30
|
"@ms-cloudpack/telemetry": "^0.3.2",
|
|
31
31
|
"chokidar": "^3.5.3",
|
|
32
32
|
"commander": "^10.0.0",
|