Skip to content

feat(contacts): add .vcf export command#519

Open
dinakars777 wants to merge 3 commits intosteipete:mainfrom
dinakars777:feature/contacts-vcf-export
Open

feat(contacts): add .vcf export command#519
dinakars777 wants to merge 3 commits intosteipete:mainfrom
dinakars777:feature/contacts-vcf-export

Conversation

@dinakars777
Copy link
Copy Markdown

Fixes #500

Feature

Add gog contacts export command that exports contacts to RFC 6350-compliant vCard (.vcf) format.

Supported Fields

  • Full name (FN) and structured name (N)
  • Multiple email addresses with type (HOME, WORK, etc.)
  • Multiple phone numbers with type
  • Postal addresses
  • Organization and title
  • URLs
  • Biography (NOTE)
  • Birthday (BDAY)

Command Options

  • --max: max results (default 100)
  • --page: page token for pagination
  • --out: output file (default stdout)
  • --match: filter contacts by name/email/phone query

Example Usage

# Export all contacts to stdout
gog contacts export

# Export to a .vcf file
gog contacts export --out contacts.vcf

# Export only contacts matching a query
gog contacts export --match "John"

# Limit results
gog contacts export --max 50 --out backup.vcf

Files Added

  • internal/cmd/contacts_vcf.go: vCard export logic
  • internal/cmd/contacts_vcf_test.go: unit tests

Testing

  • Lint passes (0 issues)
  • All new tests pass

Reviewer added 3 commits April 20, 2026 22:52
… headers

When updating a draft with --quote but without --reply-to-message-id, the
existing draft's message ID was fetched but never used to set the In-Reply-To
and References headers. This caused delivery failures on strict mail servers.

Fixes steipete#512
…gging

- Add TabId to InsertTextRequest in replaceDocsMarkdownRange
- Add TabsCriteria to cleanupDocsImagePlaceholders
- Pass TabId through runMarkdown -> replaceDocsMarkdownRange
- Add warning when using --format markdown with --tab-id (DeleteContentRange
  does not support tab targeting at API level)
- Improve error messages to include match index on failure

Fixes steipete#494
Add 'gog contacts export' command that exports contacts to RFC 6350-compliant
vCard (.vcf) format. Supports:
- Full name (FN) and structured name (N)
- Multiple email addresses with type (HOME, WORK, etc.)
- Multiple phone numbers with type
- Postal addresses
- Organization and title
- URLs
- Biography (NOTE)
- Birthday (BDAY)

New files:
- contacts_vcf.go: vCard export logic
- contacts_vcf_test.go: unit tests

Command options:
- --max: max results (default 100)
- --page: page token for pagination
- --out: output file (default stdout)
- --match: filter contacts by name/email/phone query

Fixes steipete#500
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Contacts File .vcf export

1 participant