/session-backup:daily-cowork-backupfrom MSApps Session Backup
Zips Cowork skills, plugins, and Claude docs folders and uploads them to the user's own Google Drive via a Google Apps Script web app. Confirms before uploading and never deletes user files.
Ships in MSApps Session Backup. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Zips three folders and uploads them to a Google Apps Script web app that the user deployed to their own Google account (see CONNECTORS.md). Nothing else is sent anywhere.
~/.cowork-gdrive-config.json, .env, keychains, shell profiles or any token file. The upload URL and API key come only from the plugin options (upload_url, api_key), exposed to scripts/upload.py as environment variables./backup-setup) and removed there.SESSION_MNT=$(ls -d /sessions/*/mnt 2>/dev/null | head -1) # Cowork VM; empty on a plain Mac
echo "SESSION_MNT=${SESSION_MNT:-<none, using home directory>}"
Sources (skip any that do not exist, and say so in the report):
| Zip | Source |
|---|---|
skills-backup.zip | $SESSION_MNT/.claude/skills/ (or ~/.claude/skills/) |
claude-docs-backup.zip | $SESSION_MNT/Claude/ (or ~/Documents/Claude/) |
plugins-backup.zip | $SESSION_MNT/.remote-plugins/ (or ~/.claude/plugins/) |
WORK=$(mktemp -d "${TMPDIR:-/tmp}/cowork-backup.XXXXXX")
EXCLUDES=(-x '*/node_modules/*' -x '*/.git/*' -x '*/.next/*' -x '*.pyc'
-x '*.png' -x '*.jpg' -x '*.jpeg' -x '*.gif' -x '*/package-lock.json'
-x '*/credentials/*' -x '*/.env' -x '*/.env.*' -x '*.pem' -x '*.key'
-x '*/.netrc' -x '*/id_rsa*' -x '*cowork-gdrive-config.json')
cd "<parent of the source folder>" && zip -r "$WORK/skills-backup.zip" skills/ "${EXCLUDES[@]}"
Repeat for the docs folder and the plugins folder with their zip names. The exclusions keep credential-like files and the backup config out of every zip. If claude-docs-backup.zip is over 30 MB, split it into claude-docs-gcalmcp.zip (the gcal-mcp/ subfolder) and claude-docs-rest.zip (everything else), using the same exclusions.
Show ls -lh "$WORK"/*.zip and the destination host (script.google.com), get the yes, then run:
python3 "${CLAUDE_PLUGIN_ROOT}/scripts/upload.py" "$WORK"/*.zip
upload.py refuses any host other than script.google.com / script.googleusercontent.com, uploads only .zip files into the Cowork-Backups Drive folder with replaceExisting: true, and prints each JSON result. In the Cowork VM, where the proxy blocks script.google.com, run the same command on the Mac side through Desktop Commander. If an upload fails with 413, split that zip and retry.
rm -f "$WORK"/*.zip && rmdir "$WORK"
List each uploaded file with its Drive link from the JSON response, and note any source that was skipped.
replaceExisting: true overwrites the previous backup.node_modules, .git, build caches, images, lock files, and anything credential-like (see the list above).What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
google-drive-backup, cowork-backup, session-backup, zip-upload
npx claudepluginhub msapps-mobile/claude-plugins --plugin session-backupOther plugins' skills for the same job