-
Download
credential.json
via "Enable The Drive Api" button to your working directory. https://developers.google.com/drive/api/v3/quickstart/python -
Don't forget to use virtualenv. Activate it:
virtualenv --no-site-packages .venv
source .venv/bin/activate
-
Install requirements
pip install -r requirements.txt
. -
Change data on config.py. Your can learn SPREADSHEET_ID from url of the Spreadsheet https://developers.google.com/sheets/api/guides/concepts#sheet_id
-
Run the script.
Import all csv rows:
python import_csv.py path_to_your_csv first
Import csv rows except the first line:
python import_csv.py path_to_your_csv