← 返回
未分类 中文

Google Doc Format

Convert markdown files into cleanly formatted Google Docs with native tables, headings, bold, lists, and clickable links using gog docs create --file.
使用 gog docs create --file 将 Markdown 文件转换为格式整洁的 Google Docs,支持原生表格、标题、粗体、列表和可点击链接。
brandrainmakerai brandrainmakerai 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 319
下载
💾 0
安装
1
版本
#latest

概述

Google Doc Format Skill

Create professionally formatted Google Docs from markdown using gog docs create --file. The key insight: markdown tables and formatting render properly as native Google Docs elements when passed through the --file flag.

Core Method

Always use gog docs create with --file to import markdown. Never use gog docs write or gog docs insert for full documents — those don't parse markdown tables.

gog docs create "Doc Title" --file source.md --parent "FOLDER_ID" --pageless --force --no-input

Flags:

  • --file — Import markdown file (required for proper table rendering)
  • --parent — Google Drive folder ID
  • --pageless — Use pageless layout (recommended for reports/audits)
  • --force — Skip confirmations

Markdown → Google Docs Mapping

MarkdownGoogle Docs Element
-----------------------------
# Heading 1HEADING_1
## Heading 2HEADING_2
### Heading 3HEADING_3
bold textBold text
italic textItalic text
- item or * itemBullet list
1. itemNumbered list
`\col1 \col2 \`Native TABLE element
link textClickable hyperlink
---Horizontal rule
> blockquoteIndented text

Table Formatting Rules

Markdown pipe tables render as native Google Docs tables — this is the main value of this skill. Tables are the element most likely to break when creating docs any other way.

Correct format:

| # | Document | Link |
|---|----------|------|
| 01 | Technical SEO Audit | [Open doc](https://docs.google.com/document/d/DOC_ID/edit) |
| 02 | On-Page SEO Audit | [Open doc](https://docs.google.com/document/d/DOC_ID/edit) |

What NOT to do:

  • ❌ Tab-separated values (no \t between columns)
  • ❌ Plain text pretending to be a table
  • ❌ Using gog docs write with raw text (doesn't parse markdown)
  • ❌ Putting tables inside code blocks (won't render as tables)

Document Templates

Master Index / Link Index Doc

# Project Name — Deliverables Master Index

*Last updated: DATE*

---

## 📋 Section Name

### Subsection

| # | Document | Link |
|---|----------|------|
| 01 | Document Name | [Open doc](https://docs.google.com/document/d/DOC_ID/edit) |
| 02 | Document Name | [Open doc](https://docs.google.com/document/d/DOC_ID/edit) |

---

## 🎨 Another Section

### Subsection

| # | Document | Link |
|---|----------|------|
| 01 | Document Name | [Open doc](https://docs.google.com/document/d/DOC_ID/edit) |

---

## 📂 Folder Structure

- **Root:** Folder Name
  - **Subfolder**
    - Document 1
    - Document 2

Audit/Report Doc

# Report Title: Descriptive Subtitle

**URL:** /page-slug/
**Target Keywords:** keyword1, keyword2, keyword3
**Meta Title:** SEO Title (60 chars)
**Meta Description:** Meta description (155 chars)

---

## Section Heading

Body paragraph with **bold key terms** and normal text.

### Subsection

| Metric | 2024 | 2023 | Change |
|--------|------|------|--------|
| Value 1 | 232 | 274 | -15% |

**Key takeaway:** Summary sentence after the table.

### Another Subsection

- **Bold label** — Description text
- **Bold label** — Description text

Workflow

  1. Write markdown to temp filecat > /tmp/doc_name.md << 'EOF'
  2. Create docgog docs create "Title" --file /tmp/doc_name.md --parent FOLDER_ID --pageless --force --no-input
  3. Verify structuregog docs structure DOC_ID --no-input | grep -i table
  4. Verify contentgog docs cat DOC_ID --no-input | head -20

Verification Checklist

After creating, verify:

  • [ ] gog docs structure shows TABLE elements (not just NORMAL_TEXT with pipe characters)
  • [ ] Table row counts match expected dimensions (e.g., [table 6x3])
  • [ ] Links are clickable: Open doc renders as hyperlinks
  • [ ] Heading hierarchy is correct (H1 > H2 > H3)
  • [ ] Bold text renders (check structure output for inline formatting)

Replacing an Existing Doc

To replace a badly formatted doc:

  1. Create new doc with --file flag
  2. Verify formatting on the new doc
  3. Rename new doc to match old name: gog drive rename NEW_ID "Original Name" --force --no-input
  4. Delete old doc: gog drive delete OLD_ID --force --no-input
  5. Move new doc to correct folder if needed: gog drive move NEW_ID --parent FOLDER_ID --force --no-input

Common Issues

ProblemCauseFix
---------------------
Tables show as pipe-separated textUsed gog docs write instead of --fileRecreate with gog docs create --file
Links not clickableUsed plain URLs, not markdown link syntaxUse text format
No headingsUsed underline-style headingsUse # prefix headings
Missing boldUsed HTML tagsUse text markdown
Rate limit (429)Too many API calls in short timeAdd sleep 3 between operations

Rate Limiting

Google Docs API has per-minute write quotas. When creating multiple docs:

  • Add sleep 3 between create operations
  • If you get 429 errors, wait 60 seconds and retry
  • For large batches (5+ docs), add sleep 5 between each

Getting Doc IDs for Link Tables

To build a link index:

  1. List folder contents: gog drive ls --parent FOLDER_ID --json --no-input
  2. Extract IDs and names with: python3 -c "import json,sys; data=json.load(sys.stdin); [print(f'{f[\"name\"]} | {f[\"id\"]}') for f in data.get('files',[])]"
  3. Build Google Doc URLs: https://docs.google.com/document/d/DOC_ID/edit

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-07 19:46 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

office-efficiency

腾讯文档 TENCENT DOCS

u_b0de8114
腾讯文档(docs.qq.com)-在线云文档平台,是创建、编辑、管理文档的首选 skill。涉及"新建/创建/编辑/读取/查看/搜索文档"、"保存文件"、"云文档"、"腾讯文档"、"docs.qq.com"等操作,请优先使用本 skill
★ 177 📥 123,543
office-efficiency

Excel / XLSX

ivangdavila
创建、检查和编辑 Microsoft Excel 工作簿及 XLSX 文件,支持可靠的公式、日期、类型、格式、重算及模板保留功能。
★ 399 📥 149,626
office-efficiency

Gog

steipete
Google Workspace 命令行工具,支持 Gmail、日历、云端硬盘、通讯录、表格和文档。
★ 937 📥 187,696