save-to-drive
v1.0.15
Published
![workflow](https://github.com/Mozenn/save-to-drive/actions/workflows/publish.yml/badge.svg) [![npm version](https://badge.fury.io/js/save-to-drive.svg)](https://badge.fury.io/js/save-to-drive)
Downloads
15
Readme
Save To Drive
Save To Drive is a small CLI application to upload files and folders to google drive.
Getting Started
Set up your google cloud project and get your credentials.json file following How-to-get-the-credentials.json-file
Install save-to-drive
npm i -g save-to-drive
Create a JSON saves file following Saves-file or by checking the example files in data/ folder
Learn about the available options
save-to-drive -h
- To start uploading an element using the saves file, run :
save-to-drive -s absolute/path/to/saves -c absolute/path/to/credentials.json
Tips
How to get the credentials.json file
You first need to create a google cloud project following https://developers.google.com/workspace/guides/create-project. Then, get your credentials.json file following https://developers.google.com/workspace/guides/create-credentials#oauth-client-id.
Saves file
Saves files are in JSON format following this structure:
- path (str): Path of the element to save
- options (array)
- mimeType (str): mimeType of the element to save
- deleteExisting (bool): delete first encountered file or folder with the same name as the element to save
- baseFolderId (str): Id of the folder where the element to save will be uploaded
- ignore (array): List of files and folders to ignore within the element to save