Skip to content

Commit d4194f6

Browse files
authored
Merge branch 'main' into developer.md
2 parents ab3d3ea + 34d7129 commit d4194f6

7 files changed

Lines changed: 96 additions & 55 deletions

File tree

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ body:
3838
- label: "I've updated to the latest versions"
3939

4040
- type: input
41-
id: version
41+
id: ex_version
4242
attributes:
4343
label: Extension Version
4444
description: |

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
# Copyright 2025 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
115
blank_issues_enabled: false
216
contact_links:
317
- name: Google Cloud Support

.github/sync-repo-settings.yaml

Lines changed: 0 additions & 38 deletions
This file was deleted.

.github/workflows/header-check.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Copyright 2025 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
name: 'License Header Check'
16+
17+
on:
18+
pull_request:
19+
branches: [ main ]
20+
21+
jobs:
22+
license-check:
23+
name: 'License Header Check'
24+
runs-on: ubuntu-latest
25+
steps:
26+
- name: 'Checkout Repository'
27+
uses: actions/checkout@v5
28+
29+
- name: Check License Header
30+
uses: apache/skywalking-eyes/header@v0.7.0

.licenserc.yaml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Copyright 2025 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
header:
16+
license:
17+
spdx-id: "Apache-2.0"
18+
copyright-owner: "Google LLC"
19+
paths:
20+
- "**/*.yaml"
21+
- "**/*.yml"
22+
- "**/*.toml"

README.md

Lines changed: 28 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,28 @@
66
This Gemini CLI extension provides a set of tools to interact with [PostgreSQL](https://www.postgresql.org/docs/) instances. It allows you to manage your databases, execute queries, and explore schemas directly from the [Gemini CLI](https://google-gemini.github.io/gemini-cli/), using natural language prompts.
77

88
Learn more about [Gemini CLI Extensions](https://github.com/google-gemini/gemini-cli/blob/main/docs/extensions/index.md).
9+
> [!IMPORTANT]
10+
> **We Want Your Feedback!**
11+
> Please share your thoughts with us by filling out our feedback [form][form].
12+
> Your input is invaluable and helps us improve the project for everyone.
13+
14+
[form]: https://docs.google.com/forms/d/e/1FAIpQLSfEGmLR46iipyNTgwTmIDJqzkAwDPXxbocpXpUbHXydiN1RTw/viewform?usp=pp_url&entry.157487=postgres
915

1016
## Why Use the Postgres Extension?
1117

12-
* **Natural Language Management:** Stop wrestling with complex commands. Explore schemas and query data by describing what you want in plain English.
13-
* **Seamless Workflow:** Stay in your CLI. No need to constantly switch contexts to the GCP console for common database tasks.
14-
* **Code Generation:** Accelerate development by asking Gemini to generate data classes and other code snippets based on your table schemas.
18+
* **Natural Language Management:** Stop wrestling with complex commands. Explore schemas and query data by describing what you want in plain English.
19+
* **Seamless Workflow:** Stay in your CLI. No need to constantly switch contexts to the GCP console for common database tasks.
20+
* **Code Generation:** Accelerate development by asking Gemini to generate data classes and other code snippets based on your table schemas.
21+
1522

1623
## Prerequisites
1724

1825
Before you begin, ensure you have the following:
1926

20-
* [Gemini CLI](https://github.com/google-gemini/gemini-cli) installed with version **+v0.6.0**.
21-
* A running PostgreSQL instance.
22-
* User are granted database-level permissions to execute queries.
27+
* [Gemini CLI](https://github.com/google-gemini/gemini-cli) installed with version **+v0.6.0**.
28+
* Setup Gemini CLI [Authentication](https://github.com/google-gemini/gemini-cli/tree/main?tab=readme-ov-file#-authentication-options).
29+
* A running PostgreSQL instance.
30+
* User are granted database-level permissions to execute queries.
2331

2432
## Getting Started
2533

@@ -33,13 +41,13 @@ gemini extensions install https://github.com/gemini-cli-extensions/postgres
3341

3442
### Configuration
3543

36-
Set the following environment variables before starting the Gemini CLI:
44+
Set the following environment variables before starting the Gemini CLI. These variables can be loaded from a `.env` file.
3745

38-
* `POSTGRES_HOST`: The hostname or IP address of the PostgreSQL server.
39-
* `POSTGRES_PORT`: The port number of the PostgreSQL server.
40-
* `POSTGRES_DATABASE`: The name of the database to connect to.
41-
* `POSTGRES_USER`: The username for authentication.
42-
* `POSTGRES_PASSWORD`: The password for authentication.
46+
* `POSTGRES_HOST`: The hostname or IP address of the PostgreSQL server.
47+
* `POSTGRES_PORT`: The port number of the PostgreSQL server.
48+
* `POSTGRES_DATABASE`: The name of the database to connect to.
49+
* `POSTGRES_USER`: The username for authentication.
50+
* `POSTGRES_PASSWORD`: The password for authentication.
4351

4452
### Start Gemini CLI
4553

@@ -58,12 +66,12 @@ gemini
5866

5967
Interact with Postgres using natural language right from your IDE:
6068

61-
* **Explore Schemas and Data:**
69+
* **Explore Schemas and Data:**
6270
* "Show me all tables in the 'orders' database."
6371
* "What are the columns in the 'products' table?"
6472
* "How many orders were placed in the last 30 days, and what were the top 5 most purchased items?"
6573

66-
* **Generate Code:**
74+
* **Generate Code:**
6775
* "Generate a Python dataclass to represent the 'customers' table."
6876

6977
## Supported Tools
@@ -88,6 +96,11 @@ Find additional extensions to support your entire software development lifecycle
8896

8997
## Troubleshooting
9098

99+
Use `gemini --debug` to enable debugging.
100+
101+
Common issues:
102+
103+
* "failed to find default credentials: google: could not find default credentials.": Ensure [Application Default Credentials](https://cloud.google.com/docs/authentication/gcloud) are available in your environment. See [Set up Application Default Credentials](https://cloud.google.com/docs/authentication/external/set-up-adc) for more information.
91104
* "✖ Error during discovery for server: MCP error -32000: Connection closed": The database connection has not been established. Ensure your configuration is set via environment variables.
92-
* "✖ MCP ERROR: Error: spawn /Users/<USER>/.gemini/extensions/postgres/toolbox ENOENT": The Toolbox binary did not download correctly. Ensure you are using Gemini CLI v0.6.0+.
105+
* "✖ MCP ERROR: Error: spawn /Users/USER/.gemini/extensions/postgres/toolbox ENOENT": The Toolbox binary did not download correctly. Ensure you are using Gemini CLI v0.6.0+.
93106
* "cannot execute binary file": The Toolbox binary did not download correctly. Ensure the correct binary for your OS/Architecture has been downloaded. See [Installing the server](https://googleapis.github.io/genai-toolbox/getting-started/introduction/#installing-the-server) for more information.

toolbox_version.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.16.0
1+
0.17.0

0 commit comments

Comments
 (0)