For a while it seemed that google docs / drive didn’t have a rollback function. But at least for Google Docs it has a revision history! But still – local and real backups are recommended.
A couple of hacking sessions later and it works. Essentially the documentation leaves some to wish for but essentially the basics is covered by the github-example. Which is not really an example by any mean, but its as good as it gets. Firstly a few concepts: The meta data is what matters and especially the
Trying hard to push data onto an ordinary Google Doc, but apparently it is much more common to use sheets. Other than that, the main problem was getting the OAuth2 in place. But it works. http://gspread.readthedocs.org/en/latest/oauth2.html from time import sleep from oauth2client.client import SignedJwtAssertionCredentials import RPi.GPIO as GPIO import gspread import json #Google Sheets GDOCS_CRED