mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-07-23 00:01:24 -07:00
Compare commits
16 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| b16ea4ea66 | |||
| 2defdcff1e | |||
| 40b88d8283 | |||
| 866c8ed6d0 | |||
| b7b3599cc3 | |||
| 836114888a | |||
| 037399ee8a | |||
| 827bac2b83 | |||
| 9fcf653606 | |||
| 25047ad619 | |||
| 115536140b | |||
| 08964863dd | |||
| 6ef2a1da16 | |||
| 20eea1c2a2 | |||
| 64008ba349 | |||
| 36cf4e97da |
@@ -15,35 +15,27 @@ inputs:
|
||||
description: 'The branch to merge into.'
|
||||
required: true
|
||||
default: 'main'
|
||||
app-id:
|
||||
description: 'The ID of the GitHub App.'
|
||||
required: true
|
||||
private-key:
|
||||
description: 'The private key of the GitHub App.'
|
||||
github-token:
|
||||
description: 'The GitHub token to use for creating the pull request.'
|
||||
required: true
|
||||
dry-run:
|
||||
description: 'Whether to run in dry-run mode.'
|
||||
required: false
|
||||
default: 'false'
|
||||
working-directory:
|
||||
description: 'The working directory to run the commands in.'
|
||||
required: false
|
||||
default: '.'
|
||||
|
||||
runs:
|
||||
using: 'composite'
|
||||
steps:
|
||||
- name: 'Generate GitHub App Token'
|
||||
id: 'generate_token'
|
||||
if: "inputs.dry-run == 'false'"
|
||||
uses: 'actions/create-github-app-token@a8d616148505b5069dccd32f177bb87d7f39123b'
|
||||
with:
|
||||
app-id: '${{ inputs.app-id }}'
|
||||
private-key: '${{ inputs.private-key }}'
|
||||
permission-pull-requests: 'write'
|
||||
permission-contents: 'write'
|
||||
|
||||
- name: 'Create and Approve Pull Request'
|
||||
if: "inputs.dry-run == 'false'"
|
||||
env:
|
||||
GH_TOKEN: '${{ steps.generate_token.outputs.token }}'
|
||||
GH_TOKEN: '${{ inputs.github-token }}'
|
||||
shell: 'bash'
|
||||
working-directory: '${{ inputs.working-directory }}'
|
||||
run: |
|
||||
set -e
|
||||
PR_URL=$(gh pr create \
|
||||
|
||||
@@ -31,28 +31,41 @@ jobs:
|
||||
pull-requests: 'write'
|
||||
steps:
|
||||
- name: 'Checkout'
|
||||
uses: 'actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8'
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: 'Checkout Release Code'
|
||||
uses: 'actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8'
|
||||
with:
|
||||
ref: '${{ github.event.inputs.ref }}'
|
||||
path: 'release'
|
||||
fetch-depth: 0
|
||||
|
||||
- name: 'Setup Node.js'
|
||||
uses: 'actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020' # ratchet:actions/setup-node@v4
|
||||
with:
|
||||
node-version-file: '.nvmrc'
|
||||
node-version-file: './release/.nvmrc'
|
||||
cache: 'npm'
|
||||
|
||||
- name: 'Install Dependencies'
|
||||
working-directory: './release'
|
||||
run: 'npm ci'
|
||||
|
||||
- name: 'Print Inputs'
|
||||
run: |
|
||||
echo "${{ toJSON(github.event.inputs) }}"
|
||||
|
||||
- name: 'Run Tests'
|
||||
if: "${{github.event.inputs.force_skip_tests != 'true'}}"
|
||||
uses: './.github/actions/run-tests'
|
||||
with:
|
||||
gemini_api_key: '${{ secrets.GEMINI_API_KEY }}'
|
||||
working-directory: './release'
|
||||
|
||||
- name: 'Get Nightly Version'
|
||||
id: 'nightly_version'
|
||||
working-directory: './release'
|
||||
env:
|
||||
GH_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
|
||||
run: |
|
||||
@@ -73,6 +86,7 @@ jobs:
|
||||
github-token: '${{ secrets.GITHUB_TOKEN }}'
|
||||
dry-run: '${{ github.event.inputs.dry_run }}'
|
||||
previous-tag: '${{ steps.nightly_version.outputs.PREVIOUS_TAG }}'
|
||||
working-directory: './release'
|
||||
|
||||
- name: 'Create and Merge Pull Request'
|
||||
uses: './.github/actions/create-pull-request'
|
||||
@@ -80,9 +94,9 @@ jobs:
|
||||
branch-name: 'release/${{ steps.nightly_version.outputs.RELEASE_TAG }}'
|
||||
pr-title: 'chore(release): bump version to ${{ steps.nightly_version.outputs.RELEASE_VERSION }}'
|
||||
pr-body: 'Automated version bump for nightly release.'
|
||||
app-id: '${{ secrets.APP_ID }}'
|
||||
private-key: '${{ secrets.PRIVATE_KEY }}'
|
||||
github-token: '${{ secrets.GEMINI_CLI_ROBOT_GITHUB_PAT }}'
|
||||
dry-run: '${{ github.event.inputs.dry_run }}'
|
||||
working-directory: './release'
|
||||
|
||||
- name: 'Create Issue on Failure'
|
||||
if: '${{ failure() && github.event.inputs.dry_run == false }}'
|
||||
|
||||
@@ -52,15 +52,6 @@ jobs:
|
||||
- name: 'Install Script Dependencies'
|
||||
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'
|
||||
run: |-
|
||||
git config user.name "gemini-cli-robot"
|
||||
@@ -72,7 +63,7 @@ jobs:
|
||||
id: 'create_patch'
|
||||
env:
|
||||
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
|
||||
GH_TOKEN: '${{ steps.generate_token.outputs.token }}'
|
||||
GH_TOKEN: '${{ secrets.GEMINI_CLI_ROBOT_GITHUB_PAT }}'
|
||||
continue-on-error: true
|
||||
run: |
|
||||
# Capture output and display it in logs using tee
|
||||
|
||||
@@ -320,8 +320,7 @@ jobs:
|
||||
branch-name: '${{ steps.release_branch.outputs.BRANCH_NAME }}'
|
||||
pr-title: 'chore(release): bump version to ${{ needs.calculate-versions.outputs.NEXT_NIGHTLY_VERSION }}'
|
||||
pr-body: 'Automated version bump to prepare for the next nightly release.'
|
||||
app-id: '${{ secrets.APP_ID }}'
|
||||
private-key: '${{ secrets.PRIVATE_KEY }}'
|
||||
github-token: '${{ secrets.GEMINI_CLI_ROBOT_GITHUB_PAT }}'
|
||||
dry-run: '${{ github.event.inputs.dry_run }}'
|
||||
|
||||
- name: 'Create Issue on Failure'
|
||||
|
||||
Generated
+7
-7
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "@google/gemini-cli",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "@google/gemini-cli",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"workspaces": [
|
||||
"packages/*"
|
||||
],
|
||||
@@ -16880,7 +16880,7 @@
|
||||
},
|
||||
"packages/a2a-server": {
|
||||
"name": "@google/gemini-cli-a2a-server",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"dependencies": {
|
||||
"@a2a-js/sdk": "^0.3.2",
|
||||
"@google-cloud/storage": "^7.16.0",
|
||||
@@ -17151,7 +17151,7 @@
|
||||
},
|
||||
"packages/cli": {
|
||||
"name": "@google/gemini-cli",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"dependencies": {
|
||||
"@google/gemini-cli-core": "file:../core",
|
||||
"@google/genai": "1.16.0",
|
||||
@@ -17267,7 +17267,7 @@
|
||||
},
|
||||
"packages/core": {
|
||||
"name": "@google/gemini-cli-core",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"dependencies": {
|
||||
"@google-cloud/logging": "^11.2.1",
|
||||
"@google-cloud/opentelemetry-cloud-monitoring-exporter": "^0.21.0",
|
||||
@@ -17406,7 +17406,7 @@
|
||||
},
|
||||
"packages/test-utils": {
|
||||
"name": "@google/gemini-cli-test-utils",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"license": "Apache-2.0",
|
||||
"devDependencies": {
|
||||
"typescript": "^5.3.3"
|
||||
@@ -17417,7 +17417,7 @@
|
||||
},
|
||||
"packages/vscode-ide-companion": {
|
||||
"name": "gemini-cli-vscode-ide-companion",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"license": "LICENSE",
|
||||
"dependencies": {
|
||||
"@modelcontextprotocol/sdk": "^1.15.1",
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@google/gemini-cli",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"engines": {
|
||||
"node": ">=20.0.0"
|
||||
},
|
||||
@@ -14,7 +14,7 @@
|
||||
"url": "git+https://github.com/google-gemini/gemini-cli.git"
|
||||
},
|
||||
"config": {
|
||||
"sandboxImageUri": "us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.8.0-nightly.20250925.b1da8c21"
|
||||
"sandboxImageUri": "us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.8.0-nightly.20250926.2defdcff"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "cross-env node scripts/start.js",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@google/gemini-cli-a2a-server",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"private": true,
|
||||
"description": "Gemini CLI A2A Server",
|
||||
"repository": {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@google/gemini-cli",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"description": "Gemini CLI",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -25,7 +25,7 @@
|
||||
"dist"
|
||||
],
|
||||
"config": {
|
||||
"sandboxImageUri": "us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.8.0-nightly.20250925.b1da8c21"
|
||||
"sandboxImageUri": "us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.8.0-nightly.20250926.2defdcff"
|
||||
},
|
||||
"dependencies": {
|
||||
"@google/gemini-cli-core": "file:../core",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@google/gemini-cli-core",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"description": "Gemini CLI Core",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@google/gemini-cli-test-utils",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"private": true,
|
||||
"main": "src/index.ts",
|
||||
"license": "Apache-2.0",
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"name": "gemini-cli-vscode-ide-companion",
|
||||
"displayName": "Gemini CLI Companion",
|
||||
"description": "Enable Gemini CLI with direct access to your IDE workspace.",
|
||||
"version": "0.8.0-nightly.20250925.b1da8c21",
|
||||
"version": "0.8.0-nightly.20250926.2defdcff",
|
||||
"publisher": "google",
|
||||
"icon": "assets/icon.png",
|
||||
"repository": {
|
||||
|
||||
+1
-1
@@ -164,7 +164,7 @@ export function runYamllint() {
|
||||
|
||||
export function runPrettier() {
|
||||
console.log('\nRunning Prettier...');
|
||||
if (!runCommand('prettier --check .')) {
|
||||
if (!runCommand('prettier --write .')) {
|
||||
process.exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
+32
-4
@@ -36,9 +36,35 @@ run(`npm version ${versionType} --no-git-tag-version --allow-same-version`);
|
||||
|
||||
// 3. Get all workspaces and filter out the one we don't want to version.
|
||||
const workspacesToExclude = [];
|
||||
const lsOutput = JSON.parse(
|
||||
execSync('npm ls --workspaces --json --depth=0').toString(),
|
||||
);
|
||||
let lsOutput;
|
||||
try {
|
||||
lsOutput = JSON.parse(
|
||||
execSync('npm ls --workspaces --json --depth=0').toString(),
|
||||
);
|
||||
} catch (e) {
|
||||
// `npm ls` can exit with a non-zero status code if there are issues
|
||||
// with dependencies, but it will still produce the JSON output we need.
|
||||
// We'll try to parse the stdout from the error object.
|
||||
if (e.stdout) {
|
||||
console.warn(
|
||||
'Warning: `npm ls` exited with a non-zero status code. Attempting to proceed with the output.',
|
||||
);
|
||||
try {
|
||||
lsOutput = JSON.parse(e.stdout.toString());
|
||||
} catch (parseError) {
|
||||
console.error(
|
||||
'Error: Failed to parse JSON from `npm ls` output even after `npm ls` failed.',
|
||||
);
|
||||
console.error('npm ls stderr:', e.stderr.toString());
|
||||
console.error('Parse error:', parseError);
|
||||
process.exit(1);
|
||||
}
|
||||
} else {
|
||||
console.error('Error: `npm ls` failed with no output.');
|
||||
console.error(e.stderr?.toString() || e);
|
||||
process.exit(1);
|
||||
}
|
||||
}
|
||||
const allWorkspaces = Object.keys(lsOutput.dependencies || {});
|
||||
const workspacesToVersion = allWorkspaces.filter(
|
||||
(wsName) => !workspacesToExclude.includes(wsName),
|
||||
@@ -76,6 +102,8 @@ if (cliPackageJson.config?.sandboxImageUri) {
|
||||
}
|
||||
|
||||
// 6. Run `npm install` to update package-lock.json.
|
||||
run('npm install');
|
||||
run(
|
||||
'npm install --workspace packages/cli --workspace packages/core --package-lock-only',
|
||||
);
|
||||
|
||||
console.log(`Successfully bumped versions to v${newVersion}.`);
|
||||
|
||||
Reference in New Issue
Block a user