mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-24 22:55:13 +00:00
debugging (#8882)
Co-authored-by: gemini-cli-robot <gemini-cli-robot@google.com>
This commit is contained in:
11
.github/workflows/release-patch-1-create-pr.yml
vendored
11
.github/workflows/release-patch-1-create-pr.yml
vendored
@@ -36,6 +36,7 @@ jobs:
|
|||||||
contents: 'write'
|
contents: 'write'
|
||||||
pull-requests: 'write'
|
pull-requests: 'write'
|
||||||
actions: 'write'
|
actions: 'write'
|
||||||
|
workflows: 'write'
|
||||||
steps:
|
steps:
|
||||||
- name: 'Checkout'
|
- name: 'Checkout'
|
||||||
uses: 'actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8' # ratchet:actions/checkout@v5
|
uses: 'actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8' # ratchet:actions/checkout@v5
|
||||||
@@ -52,14 +53,6 @@ jobs:
|
|||||||
- name: 'Install Script Dependencies'
|
- name: 'Install Script Dependencies'
|
||||||
run: 'npm install yargs'
|
run: 'npm install yargs'
|
||||||
|
|
||||||
- name: 'Generate GitHub App Token'
|
|
||||||
id: 'generate_token'
|
|
||||||
uses: 'actions/create-github-app-token@a8d616148505b5069dccd32f177bb87d7f39123b'
|
|
||||||
with:
|
|
||||||
app-id: '${{ secrets.APP_ID }}'
|
|
||||||
private-key: '${{ secrets.PRIVATE_KEY }}'
|
|
||||||
permission-pull-requests: 'write'
|
|
||||||
permission-contents: 'write'
|
|
||||||
|
|
||||||
- name: 'Configure Git User'
|
- name: 'Configure Git User'
|
||||||
run: |-
|
run: |-
|
||||||
@@ -72,7 +65,7 @@ jobs:
|
|||||||
id: 'create_patch'
|
id: 'create_patch'
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
|
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
|
||||||
GH_TOKEN: '${{ steps.generate_token.outputs.token }}'
|
GH_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
run: |
|
run: |
|
||||||
# Capture output and display it in logs using tee
|
# Capture output and display it in logs using tee
|
||||||
|
|||||||
@@ -98,6 +98,14 @@ async function main() {
|
|||||||
// Workaround for workflow permission issues: create branch from HEAD then reset to tag
|
// Workaround for workflow permission issues: create branch from HEAD then reset to tag
|
||||||
run(`git checkout -b ${releaseBranch}`, dryRun);
|
run(`git checkout -b ${releaseBranch}`, dryRun);
|
||||||
run(`git reset --hard ${latestTag}`, dryRun);
|
run(`git reset --hard ${latestTag}`, dryRun);
|
||||||
|
|
||||||
|
// Ensure we're using GITHUB_TOKEN (with actions:write) for pushing workflow files
|
||||||
|
const githubToken = process.env.GITHUB_TOKEN;
|
||||||
|
const repo = process.env.GITHUB_REPOSITORY || 'google-gemini/gemini-cli';
|
||||||
|
if (githubToken) {
|
||||||
|
run(`git remote set-url origin https://x-access-token:${githubToken}@github.com/${repo}.git`, dryRun);
|
||||||
|
}
|
||||||
|
|
||||||
run(`git push origin ${releaseBranch}`, dryRun);
|
run(`git push origin ${releaseBranch}`, dryRun);
|
||||||
} else {
|
} else {
|
||||||
console.log(`Release branch ${releaseBranch} already exists.`);
|
console.log(`Release branch ${releaseBranch} already exists.`);
|
||||||
|
|||||||
Reference in New Issue
Block a user