zx-bulk-release 1.7.2 → 1.7.3

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,3 +1,8 @@
1
+ ## [1.7.3](https://github.com/semrel-extra/zx-bulk-release/compare/v1.7.2...v1.7.3) (2022-06-25)
2
+
3
+ ### Fixes & improvements
4
+ * fix: mv yarn install to build.js ([3d49325](https://github.com/semrel-extra/zx-bulk-release/commit/3d49325b5348a80ee6c7e4c5647f459e81130af7))
5
+
1
6
  ## [1.7.2](https://github.com/semrel-extra/zx-bulk-release/compare/v1.7.1...v1.7.2) (2022-06-25)
2
7
 
3
8
  ### Fixes & improvements
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zx-bulk-release",
3
- "version": "1.7.2",
3
+ "version": "1.7.3",
4
4
  "description": "zx-based alternative for multi-semantic-release",
5
5
  "type": "module",
6
6
  "exports": "./src/main/js/index.js",
@@ -4,7 +4,7 @@ import ini from 'ini'
4
4
  import {traverseDeps} from './deps.js'
5
5
  import {parseEnv} from './publish.js'
6
6
 
7
- export const build = (pkg, packages) => ctx(async ($) => {
7
+ export const build = (pkg, packages, root) => ctx(async ($) => {
8
8
  if (pkg.built) return true
9
9
 
10
10
  await traverseDeps(pkg, packages, async (_, {pkg}) => build(pkg, packages))
@@ -22,6 +22,9 @@ export const build = (pkg, packages) => ctx(async ($) => {
22
22
  console.log(`tested '${pkg.name}'`)
23
23
  }
24
24
  }
25
+
26
+ $.cwd = root
27
+ await $`yarn`
25
28
  }
26
29
 
27
30
  pkg.built = true
@@ -5,7 +5,7 @@ import {getSemanticChanges, resolvePkgVersion} from './analyze.js'
5
5
  import {publish, getLatest} from './publish.js'
6
6
  import {build} from './build.js'
7
7
 
8
- export const run = ({cwd = process.cwd(), env = process.env, flags = {}} = {}) => ctx(async ($) => {
8
+ export const run = async ({cwd = process.cwd(), env = process.env, flags = {}} = {}) => {
9
9
  const {packages, queue, root} = await topo({cwd})
10
10
  const dryRun = flags['dry-run'] || flags.dryRun
11
11
 
@@ -24,14 +24,11 @@ export const run = ({cwd = process.cwd(), env = process.env, flags = {}} = {}) =
24
24
  if (changes.length === 0) continue
25
25
  console.log(`semantic changes of '${name}'`, changes)
26
26
 
27
- pkg.build = await build(pkg, packages)
28
-
29
- $.cwd = cwd
30
- await $`yarn`
27
+ pkg.build = await build(pkg, packages, cwd)
31
28
 
32
29
  if (dryRun) continue
33
30
 
34
31
  await fs.writeJson(pkg.manifestPath, pkg.manifest, {spaces: 2})
35
32
  await publish(pkg, env)
36
33
  }
37
- })
34
+ }