Commit Graph

976 Commits

Author SHA1 Message Date
Peter Steinberger
ec3ac8daa5
docs(auth): clarify testing refresh token expiry 2026-04-28 08:22:58 +01:00
Peter Steinberger
2892765ea3
ci: pin workflow actions 2026-04-28 08:14:59 +01:00
Peter Steinberger
4d585b1680
fix(auth): guard manual auth token storage 2026-04-28 08:12:43 +01:00
Peter Steinberger
1eaad2556c
feat(backup): add markdown Gmail export 2026-04-28 07:29:27 +01:00
Peter Steinberger
d51e94a8ca
docs(readme): document docs tab export 2026-04-28 06:39:58 +01:00
Peter Steinberger
539de113c1
fix(gmail): reject label slash collisions 2026-04-28 06:38:02 +01:00
Peter Steinberger
1763b3905f
fix(docs): harden tab export landing
Co-authored-by: Ben Lewis <johnbenjaminlewis@gmail.com>
2026-04-28 06:30:38 +01:00
Ben Lewis
26e01cfa97
feat(cli): add --tab flag for per-tab Google Doc export
Add experimental --tab flag to `gog docs export` and `gog drive download`
that exports a single tab from a Google Doc by title or ID. Uses the
undocumented per-tab Docs export endpoint with a custom redirect policy
that rejects non-Google redirects to detect auth failures early.

(cherry picked from commit 5a741be7ce0df13f75a10bc7a70df9fbab9475da)
2026-04-28 06:09:41 +01:00
Peter Steinberger
9362a7664e
docs(readme): clarify gmail trash workflow 2026-04-28 05:40:08 +01:00
Peter Steinberger
4bd3172aa1
test(gmail): cover nested label names 2026-04-28 05:32:25 +01:00
Peter Steinberger
8f6791f9f9
refactor(googleapi): expose authenticated HTTP client
Co-authored-by: Ben Lewis <johnbenjaminlewis@gmail.com>
2026-04-28 05:08:14 +01:00
Peter Steinberger
7ee069d88d
feat(backup): push gmail checkpoints asynchronously 2026-04-28 04:52:13 +01:00
Peter Steinberger
8addfcee8b
fix(auth): backfill account subjects on refresh 2026-04-28 04:19:39 +01:00
Peter Steinberger
532601a0f1
fix(auth): preserve accounts across Google email renames 2026-04-28 04:01:06 +01:00
Peter Steinberger
d6111be738
fix(backup): split gmail checkpoints by plaintext size 2026-04-28 04:01:00 +01:00
Peter Steinberger
7b9197ebd1
feat(auth): add auth doctor diagnostics 2026-04-28 02:49:38 +01:00
Peter Steinberger
b58964cc89
fix(backup): shrink gmail checkpoint shards 2026-04-28 02:29:31 +01:00
Peter Steinberger
8e4f5acebb
fix(drive): support stdout downloads 2026-04-28 02:26:43 +01:00
Peter Steinberger
e30d870b3f
feat(contacts): export vCards
Co-authored-by: Dinakar Sarbada <dinakars777@users.noreply.github.com>
2026-04-28 02:01:07 +01:00
Peter Steinberger
81cedf4e9e
fix(backup): ignore interrupted shard temps 2026-04-28 01:46:50 +01:00
Peter Steinberger
9d7ca4ec5f
feat(backup): checkpoint long gmail fetches 2026-04-28 01:41:58 +01:00
Peter Steinberger
e6b6046bb1
fix(slides): harden text edit commands 2026-04-28 01:18:26 +01:00
Chris Sanchez
d047a0325f
feat(slides): add insert-text and replace-text commands
Thin wrappers around presentations.batchUpdate for surgical text edits on
an existing deck.

- insert-text inserts text into a page element by objectId, with
  --insertion-index, --replace (emits DeleteText+InsertText), and
  stdin support via '-'.
- replace-text runs ReplaceAllText across the deck, with --match-case
  and repeatable --page for slide-scoped replacements.

Both honor the global --dry-run (prints the batchUpdate request body as
JSON without calling the API) and --json (emits the full
BatchUpdatePresentationResponse). Plain output gives a one-line
confirmation with revisionId + replies/replaced count. Style mirrors
existing update-notes and replace-slide commands.
2026-04-28 01:10:16 +01:00
Peter Steinberger
0d93cb2a05
refactor(slides): share speaker notes helpers 2026-04-28 01:09:34 +01:00
Peter Steinberger
65db353926
fix(docs): format markdown append writes
Co-authored-by: Eric Liu <eric@ericxliu.me>
2026-04-27 23:36:18 +01:00
Peter Steinberger
6e0af2c463
test(gmail): cover html body-format search 2026-04-27 22:42:45 +01:00
Alex Hillman
d458ed435c
Delete 4a477a05f.json
Unintended commit

(cherry picked from commit 4e92450b6f12427f138c4c6c5e54a5b26ce1438a)
2026-04-27 22:38:57 +01:00
Alex Hillman
d08771e66d
feat(gmail): add --body-format flag to messages search
Supports "text" (default, existing behavior) and "html" to prefer
the HTML MIME part over plaintext. Useful for newsletter ingestion
where the HTML body contains the rich formatted content.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
(cherry picked from commit cb5499ed7b4d20a863de1aef07c58c94ecd9a9fe)
2026-04-27 22:38:57 +01:00
Peter Steinberger
3236577249
docs(readme): document drive search scopes and docs tabs 2026-04-27 22:37:59 +01:00
Peter Steinberger
617293d213
fix(docs): resolve tab titles before mutations 2026-04-27 22:32:31 +01:00
Sheng
80039c8071
feat(drive): add --drive and --parent flags to drive search
Users had no CLI-native way to scope a Drive search to a specific
shared drive or folder. Workarounds required either raw query syntax
(which only matches direct children) or direct API calls bypassing
gog entirely, defeating the purpose of the CLI.

This adds two new flags to 'drive search':

  --drive <driveId>    Scopes search to a specific shared drive using
                       corpora=drive&driveId=X. This is the Drive API's
                       proper pattern for within-drive recursive search.
                       Mutually exclusive with --no-all-drives.

  --parent <folderId>  Wraps the query with "'<folderId>' in parents"
                       to scope results to direct children of a folder
                       (matching 'drive ls --parent' semantics).
                       Mutually exclusive with --raw-query (users with
                       raw queries can include the clause themselves).

Implementation:
  * driveFilesListCallWithDriveSupport takes a new driveID argument;
    when non-empty it sets Corpora("drive").DriveId(X), overriding
    the generic Corpora("allDrives") path.
  * driveFileListOptions gains a driveID field.
  * DriveSearchCmd validates flag combinations up front.

Behavior change:
  * No-args search behavior unchanged — existing users see no change.
  * The sole caller of driveFilesListCallWithDriveSupport passes the
    new driveID from options, preserving current corpora=allDrives
    behavior by default.

Tests added:
  * TestDriveSearchCmd_WithDrive — verifies corpora=drive+driveId wire
  * TestDriveSearchCmd_WithParent — verifies query clause injection
  * TestDriveSearchCmd_DriveAndParent_Combine — verifies the common
    combo of scoping by shared drive + folder works together
  * TestDriveSearchCmd_DriveAndNoAllDrives_Conflicts
  * TestDriveSearchCmd_ParentAndRawQuery_Conflicts

(cherry picked from commit 581fbc9fc23a1f78d0773c6897ca84bdeb77dabc)
2026-04-27 22:24:18 +01:00
Ben Lewis
50f506dd3a
refactor(cli): deprecate --tab-id in favor of --tab
Rename the --tab-id flag to --tab on all docs editing commands (write,
update, insert, delete, find-replace) to match the convention already
used by cat, structure, sed, and the new export command. The old
--tab-id flag is preserved as a hidden alias that emits a deprecation
warning to stderr.

Also switches the internal helpers (docsTargetEndIndex,
loadDocsTargetDocument) from findTabByID to findTab so that --tab
resolves by title as well as ID. Removes the now-unused findTabByID.

(cherry picked from commit 50e69365539483b8b17f697d1391656b324a67af)
2026-04-27 22:24:18 +01:00
Peter Steinberger
acb05f61a8
fix(docs): harden markdown image insertion 2026-04-27 21:33:04 +01:00
Peter Steinberger
3eb8330159
fix(gmail): use people profile for primary sender name 2026-04-27 20:55:03 +01:00
Vinoth Deivasigamani
e97cad62f6
fix(docs): size markdown images on write 2026-04-27 20:50:06 +01:00
Peter Steinberger
cb817fe65a
fix(backup): fail fast on gmail fetch errors 2026-04-27 20:46:41 +01:00
Peter Steinberger
28d9e9873a
feat(cli): improve google api hints and upload/timezone handling 2026-04-27 20:29:39 +01:00
Peter Steinberger
7f1ef97e15
fix(gmail): constrain system-label searches 2026-04-27 14:59:02 +01:00
Peter Steinberger
c4df6c34ea
fix(calendar): localize listed event times 2026-04-27 13:59:14 +01:00
Peter Steinberger
6bdc215191
test(gmail): satisfy timezone date lint 2026-04-27 13:40:59 +01:00
Peter Steinberger
2c48bd8666
fix(gmail): honor configured timezone for sent mail dates
Co-authored-by: Dinakar Sarbada <dinakars777@users.noreply.github.com>
2026-04-27 13:36:38 +01:00
Peter Steinberger
8409571d60
fix(gmail): preserve renewed watch state 2026-04-27 13:31:27 +01:00
Peter Steinberger
9ab348356a
perf(backup): bound gmail fetch memory 2026-04-27 13:17:13 +01:00
Peter Steinberger
b8f53df696
perf(backup): stream gmail backup shards 2026-04-27 13:13:52 +01:00
Peter Steinberger
ff5e85b159
feat(backup): resume full gmail backups 2026-04-27 13:02:43 +01:00
Peter Steinberger
eb6886633d
fix(backup): bound drive content exports 2026-04-27 12:42:34 +01:00
Peter Steinberger
198407c252
perf(backup): parallelize drive collaboration scan 2026-04-27 12:23:33 +01:00
Peter Steinberger
a4f8bed267
fix(backup): use valid contact group field mask 2026-04-27 12:11:35 +01:00
Peter Steinberger
efc3df2ed8
feat(backup): expand google backup coverage 2026-04-27 12:09:37 +01:00
Peter Steinberger
8e48087457
test(secrets): fix Windows lint spacing 2026-04-27 11:44:29 +01:00