To share a local file via Google Drive without API credentials (no Drive API scope, no rclone or gdrive setup):
- Copy the file into the mounted Drive, e.g.
~/Library/CloudStorage/GoogleDrive-you@domain_tld/My Drive/(the@stays and dots in the domain become_). - After the sync (~15 s for a 330 KB file), read the ID from the xattr:
xattr -p 'com.google.drivefs.item-id#S' "$HOME/Library/CloudStorage/GoogleDrive-you@domain_tld/My Drive/file.jsonl"
# -> a 33-char Drive file id (e.g. 1abc123...)The attribute doesn't exist until the upload finishes, so poll for it.
3. Open https://drive.google.com/file/d/<id>/view?authuser=you@domain.tld in the signed-in browser and set Share > General access > Anyone with the link. The mount has no way to change sharing.
4. Check that it's really public, with no cookies:
curl -sL "https://drive.google.com/uc?export=download&id=<id>" | shasum -a 256If the hash matches the local file, it's public. A restricted file returns a sign-in HTML page instead, so the hash won't match. (Large files can return a virus-scan interstitial; that check was not needed at 330 KB.)
In Workspace domains the General access menu lists Restricted / <Org name> / Anyone with the link; an admin policy can hide the last option.