Skip to main content

gcalendar

PyPI version Donate

A command-line tool to read your Google Calendar events in JSON format.

Installation

Ubuntu, Linux Mint and other Ubuntu Derivatives

sudo add-apt-repository ppa:slgobinath/gcalendar
sudo apt update
sudo apt install gcalendar

Arch

yay -S gcalendar

OR

packer -S gcalendar

Other Distributions

Install these dependencies:

python3-pip python3-setuptools python3-dateutil python3-oauth2client python3-googleapi

Install gcalendar:

pip3 install gcalendar

Install from Source

sudo apt install python3-pip python3-setuptools python3-dateutil python3-oauth2client python3-googleapi git
git clone https://github.com/slgobinath/gcalendar.git
cd gcalendar
pip3 install -e .

Run from Source

sudo apt install python3-pip python3-setuptools python3-dateutil python3-oauth2client python3-googleapi git
git clone https://github.com/slgobinath/gcalendar.git
cd gcalendar
python3 -m gcalendar

Help

usage: gcalendar [-h] [--list-calendars | --list-accounts | --status | --reset] [--calendar [CALENDAR [CALENDAR ...]]] [--no-of-days NO_OF_DAYS] [--account ACCOUNT]
                 [--output {txt,json}] [--client-id CLIENT_ID] [--client-secret CLIENT_SECRET] [--version] [--debug]

Read your Google Calendar events from terminal.

optional arguments:
  -h, --help            show this help message and exit
  --list-calendars      list all calendars from the Google account
  --list-accounts       list the id of gcalendar accounts
  --status              print the status of the gcalendar account
  --reset               reset the the account
  --calendar [CALENDAR [CALENDAR ...]]
                        calendars to list events from
  --no-of-days NO_OF_DAYS
                        number of days to include
  --account ACCOUNT     an alphanumeric name to uniquely identify the account
  --output {txt,json}   output format
  --client-id CLIENT_ID
                        the Google client id
  --client-secret CLIENT_SECRET
                        the Google client secret
  --version             show program's version number and exit
  --debug               run gcalendar in debug mode

Authorization

Run gcalendar from the terminal. It will open the Google Calendar OAthu screen in your default browser. Allow gcalendar to view your calendars as shown in this video: gcalendar Authorization.

After successful authorization, gcalendar should print calendar events on your terminal.

Usage

List Calendars

gcalendar --list-calendar

List Events

# list next 7 days events
gcalendar

# list next 30 days events
gcalendar --no-of-days 30

# list events from selected calendar
gcalendar --calendar "Holidays in Canada"

Separate Accounts

# the default account
gcalendar

# different account named foo
gcalendar --account foo

# different account named bar
gcalendar --account bar

Reset Accounts

# reset the default account
gcalendar --reset

# reset the account named foo
gcalendar --account foo --reset

# reset the account named bar
gcalendar --account bar --reset

Issues

Run gcalendar --debug and create an issue with the output.

Applications

Cinnamon Google Calendar desklet uses gcalendar to pull calendar events and show them on Cinnamon desktop.

License

GNU General Public License v3

Metadata

Release files for gcalendar 0.4.1

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

Source distribution (sdist)

Source distribution for gcalendar 0.4.1
File Size Uploaded Provenance
gcalendar-0.4.1.tar.gz 20.4 kB Without provenance Details

Release files / gcalendar-0.4.1.tar.gz

Download URL gcalendar-0.4.1.tar.gz
Size 20.4 kB
Tags Source
SHA-256 checksum
How to use checksums
462851a4c2c7317718b35cc33110dafd591dbd80109dc8a9a8a8efda45e50308
BLAKE2b-256 checksum
How to use checksums
acbc60819dc30a9cbe2e093c75d47a24dbc8555f7be31127a8a6712f996898cb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.2.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.8.5

Security for gcalendar 0.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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