Gemini CLI 是谷歌官方推出的開源AI命令行工具,它將強大的Gemini AI能力直接整合到你的終端中。這個工具旨在連接你的開發工具,理解你的程式碼,並加速你的工作流程。
項目地址: https://github.com/google-gemini/gemini-cli
npx https://github.com/google-gemini/gemini-cli
npm install -g @google/gemini-cli
當提示時,使用個人Google帳戶登入,這將為你提供:
如果需要使用特定模型或更高的請求容量:
export GEMINI_API_KEY="YOUR_API_KEY"
$ cd new-project/
$ gemini
> Write me a Gemini Discord bot that answers questions using a FAQ.md file I will provide
$ git clone https://github.com/google-gemini/gemini-cli
$ cd gemini-cli
$ gemini
> Give me a summary of all of the changes that went in yesterday
> Describe the main pieces of this system's architecture.
> What security mechanisms are in place?
> Implement a first draft for GitHub issue #123.
> Help me migrate this codebase to the latest version of Java. Start with a plan.
> Make me a slide deck showing the git history from the last 7 days, grouped by feature and team member.
> Make a full-screen web app for a wall display to show our most interacted-with GitHub issues.
> Convert all the images in this directory to png, and rename them to use dates from the exif data.
> Organise my PDF invoices by month of expenditure.
Gemini CLI 代表了AI與開發工具整合的新趨勢,它不僅僅是一個簡單的AI聊天工具,而是一個完整的AI驅動的開發環境。透過將Gemini的強大AI能力直接整合到命令行中,開發者可以:
Gemini CLI 項目體現了谷歌在AI工具實用化方面的努力,為開發者社群提供了一個強大而靈活的AI程式設計助手。