@toptal/davinci-monorepo 9.0.3-alpha-MP-469-1573babd.19 → 9.0.3-alpha-MP-469-f3f2c8cc.20
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/package.json +3 -3
- package/src/index.js +2 -5
- package/src/utils/get-packages.js +3 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@toptal/davinci-monorepo",
|
|
3
|
-
"version": "9.0.3-alpha-MP-469-
|
|
3
|
+
"version": "9.0.3-alpha-MP-469-f3f2c8cc.20+f3f2c8cc",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"lint"
|
|
6
6
|
],
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"@nodelib/fs.walk": "^1.2.6",
|
|
29
29
|
"@oclif/core": "^1.16.1",
|
|
30
|
-
"@toptal/davinci-cli-shared": "2.5.2-alpha-MP-469-
|
|
30
|
+
"@toptal/davinci-cli-shared": "2.5.2-alpha-MP-469-f3f2c8cc.22+f3f2c8cc",
|
|
31
31
|
"chalk": "^4.1.2",
|
|
32
32
|
"codeowners": "5.1.1",
|
|
33
33
|
"dependency-cruiser": "^16.3.0",
|
|
@@ -50,5 +50,5 @@
|
|
|
50
50
|
"publishConfig": {
|
|
51
51
|
"access": "public"
|
|
52
52
|
},
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "f3f2c8cca781fc088dd2a28a1f9a0deec50021b2"
|
|
54
54
|
}
|
package/src/index.js
CHANGED
|
@@ -5,15 +5,12 @@ import { createCodeownersCommand } from './commands/codeowners/index.js'
|
|
|
5
5
|
import { createCoverageCommand } from './commands/coverage-command/index.js'
|
|
6
6
|
import { hostsCommandFactory } from './commands/hosts/index.js'
|
|
7
7
|
import checkIfMonorepo from './utils/check-if-monorepo.js'
|
|
8
|
-
import {
|
|
9
|
-
getPackages,
|
|
10
|
-
getChangedPackagesLocations,
|
|
11
|
-
} from './utils/get-packages.js'
|
|
8
|
+
import { getPackages, getPackagesLocations } from './utils/get-packages.js'
|
|
12
9
|
|
|
13
10
|
export const utils = {
|
|
14
11
|
checkIfMonorepo,
|
|
15
12
|
getPackages,
|
|
16
|
-
|
|
13
|
+
getPackagesLocations,
|
|
17
14
|
}
|
|
18
15
|
|
|
19
16
|
export const commands = [
|
|
@@ -119,13 +119,13 @@ export const getPackages = async ({
|
|
|
119
119
|
return await performPackagesSearch(commandArgs)
|
|
120
120
|
}
|
|
121
121
|
|
|
122
|
-
export const
|
|
123
|
-
const
|
|
122
|
+
export const getPackagesLocations = async ({ onlyAffected = true }) => {
|
|
123
|
+
const packageNames = await getPackages({ onlyAffected }) // [name, ...]
|
|
124
124
|
const allPackages = getPackagesLegacy('.') // [{name, location}, ...]
|
|
125
125
|
|
|
126
126
|
// [location, ...]
|
|
127
127
|
return allPackages
|
|
128
|
-
.filter(pkg =>
|
|
128
|
+
.filter(pkg => packageNames.includes(pkg.name))
|
|
129
129
|
.map(pkg => pkg.location)
|
|
130
130
|
}
|
|
131
131
|
|