refactored GDrive code to be a little more generic