@storm-software/workspace-tools 1.174.0 → 1.175.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.
- package/CHANGELOG.md +19 -0
- package/README.md +1 -1
- package/index.js +52 -11
- package/meta.json +1 -1
- package/package.json +1 -1
- package/src/executors/rollup/executor.js +4 -1
- package/src/utils/index.d.ts +1 -0
- package/src/utils/index.js +38 -0
- package/src/utils/package-helpers.d.ts +13 -0
package/package.json
CHANGED
|
@@ -717983,7 +717983,10 @@ async function* rollupExecutorFn(options, context, config) {
|
|
|
717983
717983
|
options.additionalEntryPoints?.map(
|
|
717984
717984
|
(entry) => correctPaths2((0, import_path.join)(workspaceRoot, entry))
|
|
717985
717985
|
) ?? []
|
|
717986
|
-
)
|
|
717986
|
+
).map((entry) => {
|
|
717987
|
+
const formatted = entry.replace(workspaceRoot, "");
|
|
717988
|
+
return formatted.endsWith("/") ? formatted.slice(-1) : formatted;
|
|
717989
|
+
});
|
|
717987
717990
|
}
|
|
717988
717991
|
writeDebug2(
|
|
717989
717992
|
`\u{1F4E6} Running Storm Rollup build process on the ${context?.projectName} project`,
|
package/src/utils/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ export * from "./cargo";
|
|
|
3
3
|
export * from "./create-cli-options";
|
|
4
4
|
export * from "./get-project-configurations";
|
|
5
5
|
export * from "./lock-file";
|
|
6
|
+
export * from "./package-helpers";
|
|
6
7
|
export * from "./project-tags";
|
|
7
8
|
export * from "./toml";
|
|
8
9
|
export * from "./typia-transform";
|
package/src/utils/index.js
CHANGED
|
@@ -298978,6 +298978,7 @@ __export(utils_exports, {
|
|
|
298978
298978
|
NPM_LOCK_PATH: () => NPM_LOCK_PATH,
|
|
298979
298979
|
PNPM_LOCK_FILE: () => PNPM_LOCK_FILE,
|
|
298980
298980
|
PNPM_LOCK_PATH: () => PNPM_LOCK_PATH,
|
|
298981
|
+
PackageManagerTypes: () => PackageManagerTypes,
|
|
298981
298982
|
ProjectTagConstants: () => ProjectTagConstants,
|
|
298982
298983
|
YARN_LOCK_FILE: () => YARN_LOCK_FILE,
|
|
298983
298984
|
YARN_LOCK_PATH: () => YARN_LOCK_PATH,
|
|
@@ -298995,6 +298996,7 @@ __export(utils_exports, {
|
|
|
298995
298996
|
getLockFileDependencies: () => getLockFileDependencies,
|
|
298996
298997
|
getLockFileName: () => getLockFileName,
|
|
298997
298998
|
getLockFileNodes: () => getLockFileNodes,
|
|
298999
|
+
getPackageInfo: () => getPackageInfo,
|
|
298998
299000
|
getProjectConfiguration: () => getProjectConfiguration,
|
|
298999
299001
|
getProjectConfigurations: () => getProjectConfigurations,
|
|
299000
299002
|
getProjectTag: () => getProjectTag,
|
|
@@ -299369,6 +299371,10 @@ function isPostInstallProcess() {
|
|
|
299369
299371
|
return process.env.npm_command === "install" && process.env.npm_lifecycle_event === "postinstall";
|
|
299370
299372
|
}
|
|
299371
299373
|
|
|
299374
|
+
// packages/workspace-tools/src/utils/package-helpers.ts
|
|
299375
|
+
var import_devkit4 = require("@nx/devkit");
|
|
299376
|
+
var import_node_fs12 = require("node:fs");
|
|
299377
|
+
|
|
299372
299378
|
// packages/workspace-tools/src/utils/project-tags.ts
|
|
299373
299379
|
var ProjectTagConstants = {
|
|
299374
299380
|
Language: {
|
|
@@ -302356,6 +302362,36 @@ function modifyCargoNestedTable(toml, section, key, value2) {
|
|
|
302356
302362
|
toml[section][key] = _export.Section(value2);
|
|
302357
302363
|
}
|
|
302358
302364
|
|
|
302365
|
+
// packages/workspace-tools/src/utils/package-helpers.ts
|
|
302366
|
+
var PackageManagerTypes = {
|
|
302367
|
+
PackageJson: "package.json",
|
|
302368
|
+
CargoToml: "Cargo.toml"
|
|
302369
|
+
};
|
|
302370
|
+
var getPackageInfo = (project) => {
|
|
302371
|
+
if (isEqualProjectTag(
|
|
302372
|
+
project,
|
|
302373
|
+
ProjectTagConstants.Language.TAG_ID,
|
|
302374
|
+
ProjectTagConstants.Language.RUST
|
|
302375
|
+
) && (0, import_node_fs12.existsSync)((0, import_devkit4.joinPathFragments)(project.root, "Cargo.toml"))) {
|
|
302376
|
+
return {
|
|
302377
|
+
type: "Cargo.toml",
|
|
302378
|
+
content: parseCargoToml((0, import_devkit4.joinPathFragments)(project.root, "Cargo.toml"))
|
|
302379
|
+
};
|
|
302380
|
+
} else if (isEqualProjectTag(
|
|
302381
|
+
project,
|
|
302382
|
+
ProjectTagConstants.Language.TAG_ID,
|
|
302383
|
+
ProjectTagConstants.Language.TYPESCRIPT
|
|
302384
|
+
) && (0, import_node_fs12.existsSync)((0, import_devkit4.joinPathFragments)(project.root, "package.json"))) {
|
|
302385
|
+
return {
|
|
302386
|
+
type: "package.json",
|
|
302387
|
+
content: (0, import_devkit4.readJsonFile)(
|
|
302388
|
+
(0, import_devkit4.joinPathFragments)(project.root, "package.json")
|
|
302389
|
+
)
|
|
302390
|
+
};
|
|
302391
|
+
}
|
|
302392
|
+
return null;
|
|
302393
|
+
};
|
|
302394
|
+
|
|
302359
302395
|
// packages/workspace-tools/src/utils/typia-transform.ts
|
|
302360
302396
|
var import_transform = __toESM(require_transform());
|
|
302361
302397
|
var getTypiaTransform = (program, diagnostics) => (0, import_transform.default)(program, {}, { addDiagnostic: (input) => diagnostics.push(input) });
|
|
@@ -302387,6 +302423,7 @@ var pnpmVersion = "8.10.2";
|
|
|
302387
302423
|
NPM_LOCK_PATH,
|
|
302388
302424
|
PNPM_LOCK_FILE,
|
|
302389
302425
|
PNPM_LOCK_PATH,
|
|
302426
|
+
PackageManagerTypes,
|
|
302390
302427
|
ProjectTagConstants,
|
|
302391
302428
|
YARN_LOCK_FILE,
|
|
302392
302429
|
YARN_LOCK_PATH,
|
|
@@ -302404,6 +302441,7 @@ var pnpmVersion = "8.10.2";
|
|
|
302404
302441
|
getLockFileDependencies,
|
|
302405
302442
|
getLockFileName,
|
|
302406
302443
|
getLockFileNodes,
|
|
302444
|
+
getPackageInfo,
|
|
302407
302445
|
getProjectConfiguration,
|
|
302408
302446
|
getProjectConfigurations,
|
|
302409
302447
|
getProjectTag,
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ProjectConfiguration } from "@nx/devkit";
|
|
2
|
+
import type { PackageJson } from "nx/src/utils/package-json.js";
|
|
3
|
+
import { CargoToml } from "./toml";
|
|
4
|
+
export type PackageManagerType = "package.json" | "Cargo.toml";
|
|
5
|
+
export declare const PackageManagerTypes: {
|
|
6
|
+
PackageJson: PackageManagerType;
|
|
7
|
+
CargoToml: PackageManagerType;
|
|
8
|
+
};
|
|
9
|
+
export type PackageInfo = {
|
|
10
|
+
content: PackageJson | CargoToml;
|
|
11
|
+
type: PackageManagerType;
|
|
12
|
+
};
|
|
13
|
+
export declare const getPackageInfo: (project: ProjectConfiguration) => null | PackageInfo;
|