diff --git a/README.md b/README.md index 39d8d4b4d..1d7610e90 100644 --- a/README.md +++ b/README.md @@ -170,7 +170,7 @@ go to the [Gemini Assistant workflow documentation](./examples/workflows/gemini- - use_gemini_code_assist: _(Optional, default: `false`)_ Whether to use Code Assist for Gemini model access instead of the default Gemini API key. For more information, see the [Gemini CLI documentation](https://github.com/google-gemini/gemini-cli/blob/main/docs/cli/authentication.md). -- gemini_cli_version: _(Optional, default: `latest`)_ The version of the Gemini CLI to install. +- gemini_cli_version: _(Optional, default: `latest`)_ The version of the Gemini CLI to install. Can be "latest", "preview", "nightly", a specific version number, or a git branch, tag, or commit. For more information, see [Gemini CLI releases](https://github.com/google-gemini/gemini-cli/blob/main/docs/releases.md). - google_api_key: _(Optional)_ The Vertex AI API key to use with Gemini. diff --git a/action.yml b/action.yml index 7558bb263..78660a58f 100644 --- a/action.yml +++ b/action.yml @@ -56,7 +56,7 @@ inputs: required: false default: 'false' gemini_cli_version: - description: 'The version of the Gemini CLI to install.' + description: 'The version of the Gemini CLI to install. Can be "latest", "preview", "nightly", a specific version number, or a git branch, tag, or commit. For more information, see [Gemini CLI releases](https://github.com/google-gemini/gemini-cli/blob/main/docs/releases.md).' required: false default: 'latest' google_api_key: @@ -132,7 +132,7 @@ runs: VERSION_INPUT="${GEMINI_CLI_VERSION:-latest}" - if [[ "${VERSION_INPUT}" == "latest" || "${VERSION_INPUT}" =~ ^[0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9\.-]+)?(\+[a-zA-Z0-9\.-]+)?$ ]]; then + if [[ "${VERSION_INPUT}" == "latest" || "${VERSION_INPUT}" == "preview" || "${VERSION_INPUT}" == "nightly" || "${VERSION_INPUT}" =~ ^[0-9]+\.[0-9]+\.[0-9]+(-[a-zA-Z0-9\.-]+)?(\+[a-zA-Z0-9\.-]+)?$ ]]; then echo "Installing Gemini CLI from npm: @google/gemini-cli@${VERSION_INPUT}" npm install --silent --no-audit --prefer-offline --global @google/gemini-cli@"${VERSION_INPUT}" else