Skip to content

Commit

Permalink
deploy: use gh CLI to generate releases
Browse files Browse the repository at this point in the history
  • Loading branch information
isaacs committed Sep 28, 2023
1 parent 0817604 commit b89f92c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions scripts/version.mts
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,11 @@ const git = (...args: string[]) => {
return run('git', args, { stdio: [null, 'pipe', 'inherit'] })
}

const gh = (...args: string[]) => {
console.log(`gh ${args.map(a => JSON.stringify(a)).join(' ')}`)
return run('gh', args, { stdio: [null, 'inherit', 'inherit'] })
}

// don't proceed if there are changes in the project
const assertNoChanges = () => {
const changes = git('status', '-s', '-uno', 'src')
Expand Down Expand Up @@ -419,6 +424,10 @@ const publish = (names: string[], pre: boolean = false) => {
`--tag=${pre ? 'pre' : 'latest'}`,
'-w=tap'
)
const tapVersion = manifests.tap.version
if (tapVersion) {
gh('release', 'create', `tap@${tapVersion}`, '--generate-notes')
}
}
}

Expand Down

0 comments on commit b89f92c

Please sign in to comment.