Friday 12 July 2019

Google Drive integration on Linux

Now, I'm in the I.T. minority - I actually use a linux desktop (anyone who knows me know that I hate Micro$oft with a passion, and won't touch even pirated copies of their overbloated insecure counter-intuitive standards-breaking non-rfc-compliant pile of pirated code that they laughingly call an "operating" system).
One of the problems with Linux has been decent Google Drive integration -- which seems weird really considering Google's supposed love of free software and support for it.  However, there is a lovely little program called GRIVE that will sync the contents of your Google Drive to a local directory and vice-versa.  Unfortunately it doesn't work with any Google Documents you have due to the way they are stored by Google.  They are not physical files (that's why you have to export them if you want to save a GoogleDoc in a different format; these WILL be sync'ed) so can't be copied across by grive.

I have this in my user crontab:
 # sync google drive using grive every xx mins.... --->
 00,10,20,30,40,50 * * * * /usr/local/bin/grive -p ~/gdrive/ -V -l ~/.grive.log
This syncs my Google Drive to a directory called gdrive/ in the root of my home directory every 10 minutes.

1 comment:

  1. Forgot to say -- you'll have to set some permissions in your Google account to allow some 'insecure' or similarly termed shit to access Google drive to get this to work. Also, first time round grive will need to generate an authentication token and secret before it is able to connect to your Google account/gdrive.

    ReplyDelete