Install PHP, composer, and Google Sheets API:
sudo apt install composer php-fpm
composer install
If this project gets unmaintained and the dependencies die out, just
update them from composer.json
:
composer update
Test it and if it works after update, then commit the changed lock file to this repo.
Create Google API key and download its credentials. Follow the instructions at Google Sheets PHP Quickstart Guide.
Then and give credentials file as an argument to login script:
./google_api_login /path/to/credentials.json
Follow script's instructions. You need to allow the access by opening the given link using your browser and then copy-paste the key back to the command line.
./upload_history JSON_DATA