Skip to content

Commit

Permalink
Release - v0.18.8 (#319)
Browse files Browse the repository at this point in the history
* Move linkedom to dependencies (#316)

* Use nextVersion not inferred version for publish (#318)
  • Loading branch information
JAForbes authored Apr 28, 2022
1 parent 9211bbc commit 3b9ef85
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,7 @@ async function merge(options){
? await changelog({ ...changelogOut })
: await extractChangelog({})

let { version } = out
let { nextVersion } = out
let [owner,repo] = process.env.GITHUB_REPOSITORY.split('/')

let sourceSHA =
Expand Down Expand Up @@ -616,10 +616,10 @@ async function merge(options){
,repo
})

let found = allTags.find( x => x.name == `v`+ version )
let found = allTags.find( x => x.name == `v`+ nextVersion )

if( found ) {
info( 'Version tag', version, 'already exists, exiting with code zero.')
info( 'Version tag', nextVersion, 'already exists, exiting with code zero.')
return null;
}
}
Expand All @@ -633,7 +633,7 @@ async function merge(options){
commit: if (options.commit){

if( await fs.stat('package.json').catch( () => null ) ) {
await $`npm version --no-verify --no-commit-hooks --no-git-tag-version ${version}`.exitCode
await $`npm version --no-verify --no-commit-hooks --no-git-tag-version ${nextVersion}`.exitCode
}

// todo-james make this a standalone command
Expand Down Expand Up @@ -676,7 +676,7 @@ async function merge(options){
let commit = await octokit.rest.git.createCommit({
owner
, repo
, message: (options.message || 'Release Artifacts for v'+version)
, message: (options.message || 'Release Artifacts for v'+nextVersion)
+`\n\n [skip ci]`
, tree: tree.data.sha
, parents: [base_tree]
Expand Down Expand Up @@ -711,8 +711,8 @@ async function merge(options){
await octokit.rest.repos.createRelease({
owner
,repo
,tag_name: `v${version}`
,name: `v${version}`
,tag_name: `v${nextVersion}`
,name: `v${nextVersion}`
,target_commitish: target
,body: out.body
// extract from PR have a release notes marker section
Expand Down

0 comments on commit 3b9ef85

Please sign in to comment.