@backstage/cli-common 0.2.0-next.2 → 0.2.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 +34 -0
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,39 @@
|
|
|
1
1
|
# @backstage/cli-common
|
|
2
2
|
|
|
3
|
+
## 0.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 56bd494: Added `targetPaths` and `findOwnPaths` as replacements for `findPaths`, with a cleaner separation between target project paths and package-relative paths.
|
|
8
|
+
|
|
9
|
+
To migrate existing `findPaths` usage:
|
|
10
|
+
|
|
11
|
+
```ts
|
|
12
|
+
// Before
|
|
13
|
+
import { findPaths } from '@backstage/cli-common';
|
|
14
|
+
const paths = findPaths(__dirname);
|
|
15
|
+
|
|
16
|
+
// After — for target project paths (cwd-based):
|
|
17
|
+
import { targetPaths } from '@backstage/cli-common';
|
|
18
|
+
// paths.targetDir → targetPaths.dir
|
|
19
|
+
// paths.targetRoot → targetPaths.rootDir
|
|
20
|
+
// paths.resolveTarget('src') → targetPaths.resolve('src')
|
|
21
|
+
// paths.resolveTargetRoot('yarn.lock') → targetPaths.resolveRoot('yarn.lock')
|
|
22
|
+
|
|
23
|
+
// After — for package-relative paths:
|
|
24
|
+
import { findOwnPaths } from '@backstage/cli-common';
|
|
25
|
+
const own = findOwnPaths(__dirname);
|
|
26
|
+
// paths.ownDir → own.dir
|
|
27
|
+
// paths.ownRoot → own.rootDir
|
|
28
|
+
// paths.resolveOwn('config/jest.js') → own.resolve('config/jest.js')
|
|
29
|
+
// paths.resolveOwnRoot('tsconfig.json') → own.resolveRoot('tsconfig.json')
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
### Patch Changes
|
|
33
|
+
|
|
34
|
+
- e44b6a9: The `findOwnRootDir` utility now searches for the monorepo root by traversing up the directory tree looking for a `package.json` with `workspaces`, instead of assuming a fixed `../..` relative path. If no workspaces root is found during this traversal, `findOwnRootDir` now throws to enforce stricter validation of the repository layout.
|
|
35
|
+
- 9361965: Fixed `runCheck` to ignore stdio of the spawned process, preventing unwanted output from leaking to the terminal.
|
|
36
|
+
|
|
3
37
|
## 0.2.0-next.2
|
|
4
38
|
|
|
5
39
|
### Patch Changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/cli-common",
|
|
3
|
-
"version": "0.2.0
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "Common functionality used by cli, backend, and create-app",
|
|
5
5
|
"backstage": {
|
|
6
6
|
"role": "node-library"
|
|
@@ -56,13 +56,13 @@
|
|
|
56
56
|
"test": "backstage-cli package test"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@backstage/errors": "1.2.7",
|
|
59
|
+
"@backstage/errors": "^1.2.7",
|
|
60
60
|
"cross-spawn": "^7.0.3",
|
|
61
61
|
"global-agent": "^3.0.0",
|
|
62
62
|
"undici": "^7.2.3"
|
|
63
63
|
},
|
|
64
64
|
"devDependencies": {
|
|
65
|
-
"@backstage/cli": "0.36.0
|
|
65
|
+
"@backstage/cli": "^0.36.0",
|
|
66
66
|
"@types/cross-spawn": "^6.0.2",
|
|
67
67
|
"@types/node": "^22.13.14"
|
|
68
68
|
}
|