summaryrefslogtreecommitdiff
path: root/docs/cli
diff options
context:
space:
mode:
authorTommaso Sciortino <[email protected]>2025-06-26 08:27:20 -0700
committerGitHub <[email protected]>2025-06-26 15:27:20 +0000
commitc55b15f705d083e3dadcfb71494dcb0d6043e6c6 (patch)
tree222c608a5b1e48b0d392b8ad190b263428ab2e8c /docs/cli
parent24ccc9c4578f40317ee903f731831f42eed699d4 (diff)
Improve LoadCodeAssist error handling (#1645)
Diffstat (limited to 'docs/cli')
-rw-r--r--docs/cli/authentication.md25
1 files changed, 2 insertions, 23 deletions
diff --git a/docs/cli/authentication.md b/docs/cli/authentication.md
index 90553289..6c06b1b7 100644
--- a/docs/cli/authentication.md
+++ b/docs/cli/authentication.md
@@ -7,7 +7,7 @@ The Gemini CLI requires you to authenticate with Google's AI services. On initia
- Use this option to log in with your google account.
- During initial startup, Gemini CLI will direct you to a webpage for authentication. Once authenticated, your credentials will be cached locally so the web login can be skipped on subsequent runs.
- Note that the web login must be done in a browser that can communicate with the machine Gemini CLI is being run from. (Specifically, the browser will be redirected to a localhost url that Gemini CLI will be listening on).
- - Users may have to specify a GOOGLE_CLOUD_PROJECT if:
+ - <a id="workspace-gca">Users may have to specify a GOOGLE_CLOUD_PROJECT if:</a>
1. You have a Google Workspace account. Google Workspace is a paid service for businesses and organizations that provides a suite of productivity tools, including a custom email domain (e.g. [email protected]), enhanced security features, and administrative controls. These accounts are often managed by an employer or school.
2. You are a licensed Code Assist user. This can happen if you have previously purchased a Code Assist license or have acquired one through Google Developer Program.
- If you fall into one of these categories, you must first configure a Google Cloud Project Id to use, [enable the Gemini for Cloud API](https://cloud.google.com/gemini/docs/discover/set-up-gemini#enable-api) and [configure access permissions](https://cloud.google.com/gemini/docs/discover/set-up-gemini#grant-iam). You can temporarily set the environment variable in your current shell session using the following command:
@@ -34,28 +34,7 @@ The Gemini CLI requires you to authenticate with Google's AI services. On initia
source ~/.bashrc
```
-3. **<a id="workspace-gca"></a>Login with Google (Gemini Code Assist for Workspace or licensed Code Assist users):**
-
- (For more information, see: https://developers.google.com/gemini-code-assist/resources/faqs#gcp-project-requirement)
-
- - Use this option if:
-
- 1. You have a Google Workspace account. Google Workspace is a paid service for businesses and organizations that provides a suite of productivity tools, including a custom email domain (e.g. [email protected]), enhanced security features, and administrative controls. These accounts are often managed by an employer or school.
- 2. You are a licensed Code Assist user. This can happen if you have previously purchased a Code Assist license or have acquired one through Google Developer Program.
-
- - If you fall into one of these categories, you must first configure a Google Cloud Project Id to use, [enable the Gemini for Cloud API](https://cloud.google.com/gemini/docs/discover/set-up-gemini#enable-api) and [configure access permissions](https://cloud.google.com/gemini/docs/discover/set-up-gemini#grant-iam). You can temporarily set the environment variable in your current shell session using the following command:
- ```bash
- export GOOGLE_CLOUD_PROJECT="YOUR_PROJECT_ID"
- ```
- - For repeated use, you can add the environment variable to your `.env` file (located in the project directory or user home directory) or your shell's configuration file (like `~/.bashrc`, `~/.zshrc`, or `~/.profile`). For example, the following command adds the environment variable to a `~/.bashrc` file:
- ```bash
- echo 'export GOOGLE_CLOUD_PROJECT="YOUR_PROJECT_ID"' >> ~/.bashrc
- source ~/.bashrc
- ```
- - During startup, Gemini CLI will direct you to a webpage for authentication. Once authenticated, your credentials will be cached locally so the web login can be skipped on subsequent runs.
- - Note that the web login must be done in a browser that can communicate with the machine Gemini CLI is being run from. (Specifically, the browser will be redirected to a localhost url that Gemini CLI will be listening on).
-
-4. **Vertex AI:**
+3. **Vertex AI:**
- If not using express mode:
- Ensure you have a Google Cloud project and have enabled the Vertex AI API.
- Set up Application Default Credentials (ADC), using the following command: