Skip to content

Commit d35cb24

Browse files
build: [WIP] checkout and push instead of direct calls to GitHub API
1 parent 65305f2 commit d35cb24

1 file changed

Lines changed: 14 additions & 14 deletions

File tree

.github/workflows/generate.yaml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -41,18 +41,18 @@ jobs:
4141
pip install pip==21.3.1
4242
pip --version
4343
- run: ./google-api-java-client-services/.github/workflows/generate.sh ${{ matrix.service }}
44-
- uses: googleapis/code-suggester@v2 # takes the changes from git directory
44+
- uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0
45+
token: ${{ secrets.YOSHI_CODE_BOT_TOKEN }}
46+
commit-message: ${{ env.MESSAGE }}
47+
committer: ${{ env.AUTHOR }}
48+
author: ${{ env.AUTHOR }}
49+
branch: regenerate-${{ matrix.service }}
50+
title: ${{ env.MESSAGE }}
51+
body: 'Generated in GitHub action: https://github.com/${{ github.repository_owner }}/${{ github.repository }}/actions/workflows/codegen.yaml'
52+
add-paths: 'google-api-java-client-services/clients/google-api-services-${{ matrix.service }}'
53+
base: main
54+
push-to-fork: yoshi-code-bot/google-api-java-client-services
55+
4556
env:
46-
ACCESS_TOKEN: ${{ secrets.YOSHI_CODE_BOT_TOKEN }}
47-
with:
48-
command: pr
49-
upstream_owner: ${{ github.repository_owner }}
50-
upstream_repo: google-api-java-client-services
51-
description: 'Generated in GitHub action: https://github.com/${{ github.repository_owner }}/${{ github.repository }}/actions/workflows/codegen.yaml'
52-
title: 'chore: regenerate ${{ matrix.service }} client'
53-
message: 'chore: regenerate ${{ matrix.service }} client'
54-
branch: regenerate-${{ matrix.service }}
55-
git_dir: 'google-api-java-client-services/clients/google-api-services-${{ matrix.service }}'
56-
primary: main
57-
force: true
58-
fork: true
57+
- MESSAGE: 'chore: regenerate ${{ matrix.service }} client'
58+
- AUTHOR: Yoshi Code Bot <yoshi-automation@google.com>

0 commit comments

Comments
 (0)