Skip to main content

PyPI package Documentation Test results Test coverage Code analysis License Analytics

gdoc-down

API and command line program to save Google documents, presentations, and worksheets in a local Google Drive / Backup & Sync directory to to local files.

gdoc-down supports several formats:

  • CSV (.csv)

  • EPUB (.epub)

  • Excel workbook (.xlsx)

  • HTML (.html)

  • Image (.png, .jpg, .svg)

  • LaTeX (.tex)

  • Open Office document (.odt)

  • Open Office presentation (.odp)

  • Open Office workbook (.ods)

  • Plain text file (.txt)

  • Portable document format (.pdf)

  • Powerpoint presentation (.pptx)

  • Rich text document (.rtf)

  • TSV (.tsv)

  • Word document (.docx)

gdoc-down also has special features for handling .gdoc files that contain LaTeX:

  • gdoc-down ignores all images. This allows the user to place images inside the Google document for convenience and to use \includegraphics to embed images in compile PDF files.

  • gdoc-down will convert all Google document comments to PDF comments.

  • gdoc-down ignores all page breaks.

The first time gdoc-down is called, gdoc-down will request access to the user’s Google account. This will create a client.json file in the users home directory (~/.gdoc_down/client.json).

Installation

  • Latest release from PyPI pip install gdoc_down

  • Latest revision from GitHub pip install git+https://github.com/KarrLab/gdoc_down.git#egg=gdoc_down

Command line usage

usage: gdoc-down (sub-commands ...) [options ...] {arguments ...}

Download a Google document, presentation, or workbook to a local file

positional arguments:
  google_file           path to Google document, presentation, or workbook

optional arguments:
  -h, --help            show this help message and exit
  --debug               toggle debug output
  --quiet               suppress all output
  --format FORMAT, -f FORMAT
                        output format (csv, docx, epub, html, jpg, odft, odp,
                        ods, pdf, pptx, png, rtf, svg, tsv, tex, txt, xlsx)
  --out_path OUT_PATH, -o OUT_PATH
                        path where Google document, presentation, or workbook
                        should be downloaded
  --extension EXTENSION, -e EXTENSION
                        output extension

Examples

gdoc-down -f docx /path/to/Google \Drive/file.gdoc
gdoc-down -f pptx /path/to/Google \Drive/file.gslides
gdoc-down -f xlsx /path/to/Google \Drive/file.gsheet

Documentation

Please see the documentation at Read the Docs.

Tests

pytest can be used to run the tests:

pytest tests

Please note that several additional packages are required for testing (see tests/requirements.txt).

License

The example model is released under the MIT license.

Development team

gdoc-down was developed by Jonathan Karr at the Icahn School of Medicine at Mount Sinai in New York, USA.

Questions and comments

Please contact the Jonathan Karr with any questions or comments.

Release files for gdoc-down 0.0.10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gdoc-down 0.0.10
File Size Uploaded
gdoc_down-0.0.10.tar.gz 9.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for gdoc-down 0.0.10
File Interpreter ABI Platform
gdoc_down-0.0.10-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 19.0 kB

Release files / gdoc_down-0.0.10.tar.gz

Download URL gdoc_down-0.0.10.tar.gz
Size 9.6 kB
Tags Source
SHA-256 checksum
How to use checksums
737c33a81c2b7d6f052f10906a402c3d0494bf202ad5a3457902d56e9c1ff461
BLAKE2b-256 checksum
How to use checksums
c878eba7d966b8d23b7d1935d7dd44164d87a1c1e377c2ea8646dad775a6f5d7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.40.2 CPython/3.7.5

Release files / gdoc_down-0.0.10-py2.py3-none-any.whl

Download URL gdoc_down-0.0.10-py2.py3-none-any.whl
Size 9.4 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
653b81257bab936c1cd2d13cb31ed3c011d292c23bf3f784e52f5db51e453d7f
BLAKE2b-256 checksum
How to use checksums
123f0c7253b0d8eb412b54127c3dceaaeb6e8d1901884818b0b045cebd7dcf3e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.40.2 CPython/3.7.5

Release history Release notifications | RSS feed

This release

0.0.10 This release

2 release files

0.0.9

2 release files

0.0.8

2 release files

0.0.7

2 release files

0.0.6

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page