gdcli

Manages Google Drive files via CLI for listing, searching, uploading, downloading, and sharing.

Updated Mar 12, 2026
One-click install
npx skills add https://github.com/RavitejaKarra24/dotfiles --skill gdcli-ravitejakarra24
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gdcli
Source: https://github.com/RavitejaKarra24/dotfiles/tree/main/pi/.pi/agent/skills/pi-skills/gdcli
Command: npx skills add https://github.com/RavitejaKarra24/dotfiles --skill gdcli-ravitejakarra24

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @mariozechner/gdcli.

What problem does it solve? Working with Google Drive from the terminal or an AI agent normally requires writing custom API code or switching to a browser. This Skill provides a command-line interface for everyday Drive operations so files can be listed, searched, uploaded, downloaded, and shared without leaving the shell. ## Core Features & Use Cases - File Operations: List folders, upload and download files, create directories, and share files publicly or with specific users. - Flexible Search: Run full-text content searches with search or filter by metadata (name, MIME type, date, owner) using Drive query syntax via ls --query. - Multi-Account Support: Manage OAuth credentials and multiple Google accounts stored locally in ~/.gdcli/. - Use Case: Ask the agent to find every PDF modified this year in your Drive, download them to a local folder, and share one report publicly with a single link. ## Quick Start Use the gdcli skill to list the files in my Google Drive root folder and download the document named report.pdf.

Frequently Asked Questions about gdcli

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I search Google Drive files from the command line?

Use gdcli with two search modes: `gdcli <email> search "text"` for full-text content search, or `gdcli <email> ls --query "name contains 'report'"` for metadata filtering by name, MIME type, date, or owner.

How do I upload and download files to Google Drive with a CLI?

Run `gdcli <email> upload <localPath> --folder <folderId>` to upload and `gdcli <email> download <fileId> [destPath]` to download. Downloads default to the ~/.gdcli/downloads/ directory if no destination is given.

What setup does gdcli need before first use?

gdcli requires a Google Cloud project with the Drive API enabled and an OAuth desktop client JSON. Register it with `gdcli accounts credentials <file>`, then add an account via `gdcli accounts add <email>`, using --manual for browserless OAuth.

What is the difference between gdcli search and ls --query?

The `search` command performs full-text search inside file contents, while `ls --query` filters by metadata such as name, mimeType, modifiedTime, and owners. Use `ls --query` for filename lookups since `search` does not match titles reliably.

Can gdcli share Google Drive files publicly?

Yes, run `gdcli <email> share <fileId> --anyone` to make a file publicly accessible. Sharing requires the authenticated account to have sufficient permissions on the target file.