@backstage/cli-node 0.0.0-nightly-20260227031022 → 0.0.0-nightly-20260304030634

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  # @backstage/cli-node
2
2
 
3
- ## 0.0.0-nightly-20260227031022
3
+ ## 0.0.0-nightly-20260304030634
4
4
 
5
5
  ### Patch Changes
6
6
 
@@ -8,8 +8,21 @@
8
8
  - 06c2015: Added `runConcurrentTasks` and `runWorkerQueueThreads` utilities, moved from the `@backstage/cli` internal code.
9
9
  - 70fc178: Migrated from deprecated `findPaths` to `targetPaths` and `findOwnPaths` from `@backstage/cli-common`.
10
10
  - 3c811bf: Added `hasBackstageYarnPlugin` and `SuccessCache` exports, moved from `@backstage/cli`.
11
+ - a9d23c4: Properly support `package.json` `workspaces` field
11
12
  - Updated dependencies
12
- - @backstage/cli-common@0.0.0-nightly-20260227031022
13
+ - @backstage/cli-common@0.0.0-nightly-20260304030634
14
+ - @backstage/errors@1.2.7
15
+ - @backstage/types@1.2.2
16
+
17
+ ## 0.2.19-next.1
18
+
19
+ ### Patch Changes
20
+
21
+ - 61cb976: Added `toString()` method to `Lockfile` for serializing lockfiles back to string format.
22
+ - 3c811bf: Added `hasBackstageYarnPlugin` and `SuccessCache` exports, moved from `@backstage/cli`.
23
+ - a9d23c4: Properly support `package.json` `workspaces` field
24
+ - Updated dependencies
25
+ - @backstage/cli-common@0.2.0-next.1
13
26
  - @backstage/errors@1.2.7
14
27
  - @backstage/types@1.2.2
15
28
 
package/dist/index.d.ts CHANGED
@@ -100,7 +100,10 @@ declare class GitUtils {
100
100
  }
101
101
 
102
102
  /**
103
- * Returns try if the current project is a monorepo.
103
+ * Returns true if the current project is a monorepo.
104
+ *
105
+ * Uses a simple presence check on the `workspaces` field. Empty or invalid
106
+ * workspace config is treated as a monorepo; we do not validate patterns.
104
107
  *
105
108
  * @public
106
109
  */
@@ -11,7 +11,7 @@ async function isMonoRepo() {
11
11
  const rootPackageJsonPath = cliCommon.targetPaths.resolveRoot("package.json");
12
12
  try {
13
13
  const pkg = await fs__default.default.readJson(rootPackageJsonPath);
14
- return Boolean(pkg?.workspaces?.packages);
14
+ return Boolean(pkg?.workspaces);
15
15
  } catch (error) {
16
16
  return false;
17
17
  }
@@ -1 +1 @@
1
- {"version":3,"file":"isMonoRepo.cjs.js","sources":["../../src/monorepo/isMonoRepo.ts"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { targetPaths } from '@backstage/cli-common';\nimport fs from 'fs-extra';\n\n/**\n * Returns try if the current project is a monorepo.\n *\n * @public\n */\nexport async function isMonoRepo(): Promise<boolean> {\n const rootPackageJsonPath = targetPaths.resolveRoot('package.json');\n try {\n const pkg = await fs.readJson(rootPackageJsonPath);\n return Boolean(pkg?.workspaces?.packages);\n } catch (error) {\n return false;\n }\n}\n"],"names":["targetPaths","fs"],"mappings":";;;;;;;;;AAwBA,eAAsB,UAAA,GAA+B;AACnD,EAAA,MAAM,mBAAA,GAAsBA,qBAAA,CAAY,WAAA,CAAY,cAAc,CAAA;AAClE,EAAA,IAAI;AACF,IAAA,MAAM,GAAA,GAAM,MAAMC,mBAAA,CAAG,QAAA,CAAS,mBAAmB,CAAA;AACjD,IAAA,OAAO,OAAA,CAAQ,GAAA,EAAK,UAAA,EAAY,QAAQ,CAAA;AAAA,EAC1C,SAAS,KAAA,EAAO;AACd,IAAA,OAAO,KAAA;AAAA,EACT;AACF;;;;"}
1
+ {"version":3,"file":"isMonoRepo.cjs.js","sources":["../../src/monorepo/isMonoRepo.ts"],"sourcesContent":["/*\n * Copyright 2022 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { targetPaths } from '@backstage/cli-common';\nimport fs from 'fs-extra';\n\n/**\n * Returns true if the current project is a monorepo.\n *\n * Uses a simple presence check on the `workspaces` field. Empty or invalid\n * workspace config is treated as a monorepo; we do not validate patterns.\n *\n * @public\n */\nexport async function isMonoRepo(): Promise<boolean> {\n const rootPackageJsonPath = targetPaths.resolveRoot('package.json');\n try {\n const pkg = await fs.readJson(rootPackageJsonPath);\n return Boolean(pkg?.workspaces);\n } catch (error) {\n return false;\n }\n}\n"],"names":["targetPaths","fs"],"mappings":";;;;;;;;;AA2BA,eAAsB,UAAA,GAA+B;AACnD,EAAA,MAAM,mBAAA,GAAsBA,qBAAA,CAAY,WAAA,CAAY,cAAc,CAAA;AAClE,EAAA,IAAI;AACF,IAAA,MAAM,GAAA,GAAM,MAAMC,mBAAA,CAAG,QAAA,CAAS,mBAAmB,CAAA;AACjD,IAAA,OAAO,OAAA,CAAQ,KAAK,UAAU,CAAA;AAAA,EAChC,SAAS,KAAA,EAAO;AACd,IAAA,OAAO,KAAA;AAAA,EACT;AACF;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@backstage/cli-node",
3
- "version": "0.0.0-nightly-20260227031022",
3
+ "version": "0.0.0-nightly-20260304030634",
4
4
  "description": "Node.js library for Backstage CLIs",
5
5
  "backstage": {
6
6
  "role": "node-library"
@@ -31,7 +31,7 @@
31
31
  "test": "backstage-cli package test"
32
32
  },
33
33
  "dependencies": {
34
- "@backstage/cli-common": "0.0.0-nightly-20260227031022",
34
+ "@backstage/cli-common": "0.0.0-nightly-20260304030634",
35
35
  "@backstage/errors": "1.2.7",
36
36
  "@backstage/types": "1.2.2",
37
37
  "@manypkg/get-packages": "^1.1.3",
@@ -43,9 +43,9 @@
43
43
  "zod": "^3.25.76"
44
44
  },
45
45
  "devDependencies": {
46
- "@backstage/backend-test-utils": "0.0.0-nightly-20260227031022",
47
- "@backstage/cli": "0.0.0-nightly-20260227031022",
48
- "@backstage/test-utils": "0.0.0-nightly-20260227031022",
46
+ "@backstage/backend-test-utils": "0.0.0-nightly-20260304030634",
47
+ "@backstage/cli": "0.0.0-nightly-20260304030634",
48
+ "@backstage/test-utils": "0.0.0-nightly-20260304030634",
49
49
  "@types/yarnpkg__lockfile": "^1.1.4"
50
50
  },
51
51
  "typesVersions": {