mcpField
G
gdrv-cli

gdrv-cli

github.com/dl-alexandreProductivity145 installsUpdated 4w ago
Repository

About gdrv-cli

gdrv-cli is a command-line skill for managing Google Drive files, folders, and permissions. It supports search, uploads and downloads, with service-account or OAuth2 authentication.

Key features

  1. 01Upload files and directories
  2. 02Download by ID or query
  3. 03List and search Drive files
  4. 04Create and manage folders
  5. 05Grant and revoke permissions
  6. 06Service account and OAuth2 login

Use cases

  1. 01Back up a local directory to Drive
  2. 02Find and download report files
  3. 03Organize files into folders
  4. 04Share files or update access

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/dl-alexandre/skills --skill gdrv-cli

After installing, type/gdrv-cliin Claude Code to confirm it loaded.

Details

From the project README

Google Drive CLI

Manage Google Drive using the gdrv command-line tool.

Prerequisites

gdrv --version
export GDRV_CREDENTIALS='path/to/credentials.json'
gdrv auth login

Authentication

  • Service account or OAuth2 credentials
  • Environment variable: GDRV_CREDENTIALS
  • OAuth flow: gdrv auth login

File Operations

Upload
gdrv upload file.txt --folder "Backups"
gdrv upload ./folder --recursive --folder "Archive"
Download
gdrv download FILE_ID --output ./downloads
gdrv download --query "name contains 'Report'" --output ./reports
List & Search
gdrv list --folder "Documents" --limit 100
gdrv search "*.pdf" --folder "Reports"
gdrv list --trashed

Folder Management

gdrv folder create "New Folder" --parent PARENT_ID
gdrv folder list --parent ROOT
gdrv folder delete FOLDER_ID --confirm

Permissions

gdrv share FILE_ID --email [email protected] --role editor
gdrv share FILE_ID --anyone --role viewer
gdrv permissions list FILE_ID
gdrv permissions revoke FILE_ID PERMISSION_ID

Agent Best Practices

  1. Use folder names when possible; resolve IDs with gdrv list
  2. Recursive uploads for directory backups
  3. Query syntax for complex searches
  4. Service accounts for automation (no user interaction)

Comments

Markdown supported