To generate a native terminal application which can be used to browse, download/upload files and sync your Google Drive with a local folder.
Ensure you have a reasonably updated version of node and npm on your PC.
Clone this repository and then follow the instructions below:
$ git clone https://github.com/saurabhbatra96/drive-sync.git
$ cd drive-sync/
$ npm linkCurrently the working CLI options include:
-
ls
- Usage:
$ drive-sync ls - Description: List files in current folder.
- Usage:
-
cd
- Usage:
$ drive-sync cd <folder-name>$ drive-sync cd ..$ drive-sync cd
- Description:
- Change working directory to
- Change working directory to the one above.
- Change working directory to root.
- Usage:
-
pwd
- Usage:
$ drive-sync pwd - Description: Expose information about the current folder.
- Usage:
-
down
- Usage:
$ drive-sync down <file-name>$ drive-sync down all$ drive-sync down all --filter(Not yet implemented.)
- Description:
- Download from Drive to the directory you are currently in.
- Download all the files in the directory you are currently in.
- Download all files matching the following filters:
image: all files of the type image (png, jpg, gif, svg)pdf: all files of the type pdfzip: all files of the type zip
Note: If there are Google Docs in your folder, they will be converted to default formats and exported as well. For advanced options see drive-sync export.
- Usage:
-
export
-
Usage:
$ drive-sync export <doc-name> <format> -
Description: Export your docs (doc or spreadsheet) in the following supported formats for documents:
htmlpdfdoc (default)txt
and for Spreadsheets
xls (default for sheets)csv (only exports the first sheet)
-
-
logout
- Usage:
$ drive-sync logout - Description: Logout from your account.
- Usage:
This program is licensed under the GNU GPL v3 license. Check out License.txt for more details.
NodeJS.
If you have correctly configured your proxy settings in /etc/environment, drive-sync should work as expected. File an issue if not so.