Reference

`gog backup push`

gog backup push

Generated from gog schema --json. Do not edit this page by hand; run make docs-commands.

Export services into encrypted backup shards

#Usage

gog backup push [flags]

#Parent

#Flags

FlagTypeDefaultHelp
--access-tokenstringUse provided access token directly (bypasses stored refresh tokens; token expires in ~1h)
-a
--account
--acct
stringAccount email for API commands (gmail/calendar/chat/classroom/drive/docs/slides/contacts/tasks/people/sheets/forms/appscript/ads)
--best-effortbooltrueRecord optional service errors as backup rows and continue
--clientstringOAuth client name (selects stored credentials + token bucket)
--colorstringautoColor output: auto|always|never
--configstringBackup config path
--disable-commandsstringComma-separated list of disabled commands; dot paths allowed
--drive-binary-contentsboolInclude non-Google Drive binary file bytes in encrypted shards
--drive-collaborationbooltrueBack up Drive permissions, comments, and revision metadata
--drive-content-max-bytesint640Skip individual Drive content exports larger than this many bytes; 0 means unlimited
--drive-content-timeouttime.Duration2mPer-file Drive content export/download timeout
--drive-contentsbooltrueDownload/export Drive file contents into encrypted shards
-n
--dry-run
--dryrun
--noop
--preview
boolDo not make changes; print intended actions and exit successfully
--enable-commandsstringComma-separated list of enabled commands; dot paths allowed (restricts CLI)
-y
--force
--assume-yes
--yes
boolSkip confirmations for destructive commands
--gmail-cachebooltrueCache fetched Gmail raw messages locally so interrupted full backups can resume
--gmail-checkpoint-intervaltime.Duration30mMax time between Gmail checkpoint pushes during fetch; 0 disables time-triggered checkpoints
--gmail-checkpoint-rowsint10000Gmail messages per encrypted checkpoint chunk; 0 disables row-triggered checkpoints
--gmail-checkpointsbooltrueCommit and push incomplete encrypted Gmail checkpoints during long cached fetches
--gmail-no-sendboolfalseBlock Gmail send operations (agent safety)
--gmail-refresh-cacheboolRefetch Gmail messages even when a local backup cache entry exists
-h
--help
kong.helpFlagShow context-sensitive help.
--identitystringLocal age identity path
--include-spam-trashbooltrueInclude Gmail spam and trash
-j
--json
--machine
boolfalseOutput JSON to stdout (best for scripting)
--max
--limit
int640Max Gmail messages to export; 0 means all
--no-input
--non-interactive
--noninteractive
boolNever prompt; fail instead (useful for CI)
--no-pushboolCommit locally but do not push to the remote
-p
--plain
--tsv
boolfalseOutput stable, parseable text to stdout (TSV; no colors)
--querystringGmail query for bounded/test backups
--recipient[]stringPublic age recipient (repeatable)
--remotestringBackup Git remote URL
--repostringLocal backup repository path
--results-onlyboolIn JSON mode, emit only the primary result (drops envelope fields like nextPageToken)
--select
--pick
--project
stringIn JSON mode, select comma-separated fields (best-effort; supports dot paths). Desire path: use --fields for most commands.
--servicesstringgmailComma-separated services to back up
--shard-max-rowsint1000Max rows per encrypted shard
-v
--verbose
boolEnable verbose logging
--versionkong.VersionFlagPrint version and exit
--workspace-max-filesint0Max Docs/Sheets/Slides files per type for native Workspace metadata; 0 means all
--workspace-nativeboolFetch full native Docs/Sheets/Slides API JSON in addition to Drive exports

#See Also