Skip to content

Commit

Permalink
fix(config): include the dry-run param from input options
Browse files Browse the repository at this point in the history
be sure to include the dry-run flag from semantic release if provided.
default to false
  • Loading branch information
esatterwhite committed Mar 22, 2024
1 parent b5b3415 commit 7ddc1fa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/build-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ async function buildConfig(build_id, config, context) {
, dockerNetwork: network = 'default'
, dockerAutoClean: clean = true
, dockerBuildQuiet: quiet = true
, dryRun: dry_run = false
} = config

let name = null
Expand Down Expand Up @@ -57,6 +58,7 @@ async function buildConfig(build_id, config, context) {
, publish
, tags: array.toArray(tags)
, verifycmd
, dry_run
, args: {
SRC_DIRECTORY: path.basename(context.cwd)
, TARGET_PATH: target
Expand Down
3 changes: 3 additions & 0 deletions test/unit/build-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,13 @@ test('build-config', async (t) => {
, context: '.'
, quiet: true
, clean: true
, dry_run: false
})
})

t.test('nested workspace: target resolution', async (tt) => {
const config = await buildConfig('id', {
dryRun: true
}, {
options: {
root: t.testdirName
Expand Down Expand Up @@ -77,6 +79,7 @@ test('build-config', async (t) => {
, build: 'id'
, context: '.'
, quiet: true
, dry_run: true
, clean: true
})
})
Expand Down

0 comments on commit 7ddc1fa

Please sign in to comment.