a Python script that fetches data from a Google spreadsheet, transforms to JSON, then commits a data file to a GitHub repo.
Перейти к файлу
Mavis Ou a7af54f24e updated REAMDE 2016-09-07 13:48:34 -07:00
docs updated REAMDE 2016-09-07 13:48:34 -07:00
.gitignore relates to #14 - updating README (WIP) 2016-05-09 15:54:05 -07:00
LICENSE should have a license 2015-11-23 16:36:32 -08:00
README.md updated REAMDE 2016-09-07 13:48:34 -07:00
helper.py parse 'day' from 'timeblock' 2016-04-27 15:48:07 -07:00
requirements.txt github3.py library updated so we can use it now 2015-10-30 12:29:39 -07:00
sample.env Fixes #31 - renamed WORKSHEETS_TO_FETCH to SESSIONS_WORKSHEETS_TO_FETCH 2016-05-11 12:56:05 -07:00
update_schedule.py Fixes #38 - stripped leading 0 in session's start time 2016-06-07 16:46:59 -07:00

README.md

MoFo All-hands Schedule App Data Processor

This script is designed as a data processor helper for mofo-allhands repo. If you want to use this script as is make sure your Google Spreasheet is based on the Google spreadsheet template we designed.

This Schedule App Data Processor script handles the following tasks

  1. takes data from a Google spreadsheet,
  2. and converts it to a JSON array where each object has keys corresponding to the spreadsheet column names,
  3. then stores that JSON locally and/or automatically commits it to a GitHub repo (your schedule app repo, e.g., [MoFo All-hands schedule app](https://github.com/m ozilla/mofo- allhands)).

To run the script

  1. Create a Python virtual environment and install all the required packages. See create a Python virtual environment docs for instructions.
  2. Get API creds from GitHub and Google. See authentication docs for instructions.
  3. Share your Google Spreadsheet with the Google Service Account that you created in Step 2.
  4. Set values for environment variables and run source your-file-name.env
  5. Running update_schedule() will execute these methods in succession. You can trigger it from the command line: python update_schedule.py