googleworkspace/cli已通过检查
SKILL DETAIL
gws-drive-upload
googleworkspace/cli/gws-drive-upload
gws-drive-upload 技能提供了一种通过 gws 命令行工具将文件上传到 Google Drive 的方法。该技能会自动检测文件的 MIME 类型,并根据本地路径推断文件名,除非使用 --name 标志指定其他名称。您还可以使用 --parent 标志指定父文件夹 ID。 该技能是 Google Workspace CLI 技能集的一部分,需要先阅读 gws-shared 技能以了解身份验证和全局标志。这是一个写操作命令,执行前需要用户确认。
安装量 · 243查看来源
Installation
npx skills add https://googleworkspace/cli/
技能文件
SKILL.md
最近同步 · 2026年9月30日
SKILL.md›
---
name: gws-drive-upload
description: "Google Drive: Upload a file with automatic metadata."
metadata:
version: 0.22.5
openclaw:
category: "productivity"
requires:
bins:
- gws
cliHelp: "gws drive +upload --help"
---
# drive +upload
> **PREREQUISITE:** Read `../gws-shared/SKILL.md` for auth, global flags, and security rules. If missing, run `gws generate-skills` to create it.
Upload a file with automatic metadata
## Usage
```bash
gws drive +upload <file>
```
## Flags
| Flag | Required | Default | Description |
|------|----------|---------|-------------|
| `<file>` | ✓ | — | Path to file to upload |
| `--parent` | — | — | Parent folder ID |
| `--name` | — | — | Target filename (defaults to source filename) |
## Examples
```bash
gws drive +upload ./report.pdf
gws drive +upload ./report.pdf --parent FOLDER_ID
gws drive +upload ./data.csv --name 'Sales Data.csv'
```
## Tips
- MIME type is detected automatically.
- Filename is inferred from the local path unless --name is given.
> [!CAUTION]
> This is a **write** command — confirm with the user before executing.
## See Also
- [gws-shared](../gws-shared/SKILL.md) — Global flags and auth
- [gws-drive](../gws-drive/SKILL.md) — All manage files, folders, and shared drives commands