diff --git a/.github/workflows/generate.yml b/.github/workflows/generate.yml index 8b9385a..9ae7b10 100644 --- a/.github/workflows/generate.yml +++ b/.github/workflows/generate.yml @@ -45,8 +45,8 @@ jobs: git config --global user.email github-actions[bot]@users.noreply.github.com git config --global user.name "build bot" git status - # set the package version to be the same as the schema version git stash + # set the package version to be the same as the schema version npm version $version git stash pop npm run generate @@ -61,12 +61,12 @@ jobs: with: script: | const version = process.env.VERSION; - const { data: pullRequest } = await github.pulls.create({ + const { data: pullRequest } = await github.rest.pulls.create({ + title: `chore: release v${version}`, owner: context.repo.owner, repo: context.repo.repo, - title: `chore: release v${version}`, - head: `v${version}`, base: 'main', + head: `v${version}`, body: 'This PR was automatically generated by the build bot' }) console.log(`PR created: ${pullRequest.html_url}`)