Are there any simple app to sync a folder with google drive?

I have a folder where i save my scripts, netbeans projects i write etc. Im tired of uploading it after every new project or every edits i make. I saw some clients but i dont want to use them.

Is there a simple command line tool where i just can pick a folder and syncs it?


Solution 1:

Try rclone

sudo apt install rclone

to configure:

rclone config

Rclone is a command line program to sync files and directories to and from many platforms including Google Drive. See the official site for a full list.

Features

  • MD5/SHA1 hashes checked at all times for file integrity
  • Timestamps preserved on files
  • Partial syncs supported on a whole file basis
  • Copy mode to just copy new/changed files
  • Sync (one way) mode to make a directory identical
  • Check mode to check for file hash equality
  • Can sync to and from network, eg two different cloud accounts
  • Optional encryption (Crypt)
  • Optional cache (Cache)
  • Optional FUSE mount (rclone mount)

Solution 2:

Grive

Grive can be considered still beta quality. It simply downloads all the files in your Google Drive into the current directory. After you make some changes to the local files, run grive again and it will upload your changes back to your Google Drive. New files created locally or in Google Drive will be uploaded or downloaded respectively. Deleted files will also be "removed". Currently Grive will NOT destroy any of your files: it will only move the files to a directory named .trash or put them in the Google Drive trash. You can always recover them.

Gdrive

gdrive is a command line utility for uploading and downloading single files to your Google Drive. This tool on its own does not do synchronization of any kind, if you want that you can use googles own tool. It is meant for one-off uploads or downloads and integration with other unix tools. One use-case could be daily uploads of a backup archive for off-site storage.