mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-08-04 06:01:15 -07:00
c0389ef2d1
Bumps the actions-dependencies group with 3 updates in the / directory: [lycheeverse/lychee-action](https://github.com/lycheeverse/lychee-action), [preactjs/compressed-size-action](https://github.com/preactjs/compressed-size-action) and [google-github-actions/run-gemini-cli](https://github.com/google-github-actions/run-gemini-cli). Updates `lycheeverse/lychee-action` from 2.6.1 to 2.9.0 - [Release notes](https://github.com/lycheeverse/lychee-action/releases) - [Commits](https://github.com/lycheeverse/lychee-action/compare/885c65f3dc543b57c898c8099f4e08c8afd178a2...e7477775783ea5526144ba13e8db5eec57747ce8) Updates `preactjs/compressed-size-action` from 2.8.0 to 2.10.0 - [Release notes](https://github.com/preactjs/compressed-size-action/releases) - [Commits](https://github.com/preactjs/compressed-size-action/compare/946a292cd35bd1088e0d7eb92b69d1a8d5b5d76a...f322c295dde06a1cb7ccaef105732dd8a726d1d9) Updates `google-github-actions/run-gemini-cli` from 0.1.11 to 0.1.22 - [Release notes](https://github.com/google-github-actions/run-gemini-cli/releases) - [Changelog](https://github.com/google-github-actions/run-gemini-cli/blob/main/CHANGELOG.md) - [Commits](https://github.com/google-github-actions/run-gemini-cli/compare/a3bf79042542528e91937b3a3a6fbc4967ee3c31...f77273f4c914e4bf38440cf36a0369cb64a37489) --- updated-dependencies: - dependency-name: google-github-actions/run-gemini-cli dependency-version: 0.1.22 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: actions-dependencies - dependency-name: lycheeverse/lychee-action dependency-version: 2.9.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: actions-dependencies - dependency-name: preactjs/compressed-size-action dependency-version: 2.10.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: actions-dependencies ... Signed-off-by: dependabot[bot] <support@github.com>
108 lines
4.1 KiB
YAML
108 lines
4.1 KiB
YAML
# This workflow is triggered on every new release.
|
|
# It uses Gemini to generate release notes and creates a PR with the changes.
|
|
name: 'Generate Release Notes'
|
|
|
|
on:
|
|
release:
|
|
types: ['published']
|
|
workflow_dispatch:
|
|
inputs:
|
|
version:
|
|
description: 'New version (e.g., v1.2.3)'
|
|
required: true
|
|
type: 'string'
|
|
body:
|
|
description: 'Release notes body'
|
|
required: true
|
|
type: 'string'
|
|
time:
|
|
description: 'Release time'
|
|
required: true
|
|
type: 'string'
|
|
|
|
jobs:
|
|
generate-release-notes:
|
|
if: "github.repository == 'google-gemini/gemini-cli'"
|
|
runs-on: 'ubuntu-latest'
|
|
permissions:
|
|
contents: 'write'
|
|
pull-requests: 'write'
|
|
steps:
|
|
- name: 'Checkout repository'
|
|
uses: 'actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5' # ratchet:actions/checkout@v4
|
|
with:
|
|
persist-credentials: false
|
|
# The user-level skills need to be available to the workflow
|
|
fetch-depth: 0
|
|
ref: 'main'
|
|
|
|
- name: 'Set up Node.js'
|
|
uses: 'actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020' # ratchet:actions/setup-node@v4
|
|
with:
|
|
node-version: '20'
|
|
|
|
- name: 'Get release information'
|
|
id: 'release_info'
|
|
run: |
|
|
VERSION="${{ github.event.inputs.version || github.event.release.tag_name }}"
|
|
TIME="${{ github.event.inputs.time || github.event.release.created_at }}"
|
|
|
|
echo "VERSION=${VERSION}" >> "$GITHUB_OUTPUT"
|
|
echo "TIME=${TIME}" >> "$GITHUB_OUTPUT"
|
|
|
|
# Use a heredoc to preserve multiline release body
|
|
echo 'RAW_CHANGELOG<<EOF' >> "$GITHUB_OUTPUT"
|
|
printf "%s\n" "$BODY" >> "$GITHUB_OUTPUT"
|
|
echo 'EOF' >> "$GITHUB_OUTPUT"
|
|
env:
|
|
GH_TOKEN: '${{ secrets.GEMINI_CLI_ROBOT_GITHUB_PAT }}'
|
|
BODY: '${{ github.event.inputs.body || github.event.release.body }}'
|
|
|
|
- name: 'Validate version'
|
|
id: 'validate_version'
|
|
run: |
|
|
if echo "${{ steps.release_info.outputs.VERSION }}" | grep -q "nightly"; then
|
|
echo "Nightly release detected. Stopping workflow."
|
|
echo "CONTINUE=false" >> "$GITHUB_OUTPUT"
|
|
else
|
|
echo "CONTINUE=true" >> "$GITHUB_OUTPUT"
|
|
fi
|
|
|
|
- name: 'Generate Changelog with Gemini'
|
|
if: "steps.validate_version.outputs.CONTINUE == 'true'"
|
|
uses: 'google-github-actions/run-gemini-cli@f77273f4c914e4bf38440cf36a0369cb64a37489' # ratchet:google-github-actions/run-gemini-cli@v0
|
|
env:
|
|
GEMINI_CLI_TRUST_WORKSPACE: true
|
|
with:
|
|
upload_artifacts: 'true'
|
|
gemini_api_key: '${{ secrets.GEMINI_API_KEY }}'
|
|
prompt: |
|
|
Activate the 'docs-changelog' skill.
|
|
|
|
**Release Information:**
|
|
- New Version: ${{ steps.release_info.outputs.VERSION }}
|
|
- Release Date: ${{ steps.release_info.outputs.TIME }}
|
|
- Raw Changelog Data: ${{ steps.release_info.outputs.RAW_CHANGELOG }}
|
|
|
|
Execute the release notes generation process using the information provided.
|
|
|
|
When you are done, please output your thought process and the steps you took for future debugging purposes.
|
|
|
|
- name: 'Create Pull Request'
|
|
if: "steps.validate_version.outputs.CONTINUE == 'true'"
|
|
uses: 'peter-evans/create-pull-request@c5a7806660adbe173f04e3e038b0ccdcd758773c' # ratchet:peter-evans/create-pull-request@v6
|
|
with:
|
|
token: '${{ secrets.GEMINI_CLI_ROBOT_GITHUB_PAT }}'
|
|
commit-message: 'docs(changelog): update for ${{ steps.release_info.outputs.VERSION }}'
|
|
title: 'Changelog for ${{ steps.release_info.outputs.VERSION }}'
|
|
body: |
|
|
This PR contains the auto-generated changelog for the ${{ steps.release_info.outputs.VERSION }} release.
|
|
|
|
Please review and merge.
|
|
|
|
Related to #18505
|
|
branch: 'changelog-${{ steps.release_info.outputs.VERSION }}'
|
|
base: 'main'
|
|
team-reviewers: 'gemini-cli-docs, gemini-cli-maintainers'
|
|
delete-branch: true
|