Is it possible to directly copy from a shared gdrive link to my gdrive?

For example, I have a shared link like this:

https://drive.google.com/drive/folders/1FNQqadPB172XXXXXXXXXXXXXXXX?usp=sharing

I know I can open this link in my browser, and the shared content will be add to my gdrive under "Shared with me".
Then i can copy from this "shared with me" to my google drive using this command:

rclone copy --drive-shared-with-me GoogleDrive:/Shared_Folder_name GoogleDrive:/Path/To/Own/Drive

I am wondering is there anyway that I can copy directly from the shared link to my google drive? Maybe some magic --command like this:

rclone copy https://drive.google.com/drive/folders/1FNQqadPB172XXXXXXXXXXXXXXXX?usp=sharing  GD:/Path/To/Folder

I don't want to open the browser everytime i want to copy from the shared link, any advice on this?

rclone v1.57.0

  • os/version: debian 11.3 (64 bit)
  • os/kernel: 5.10.0-13-amd64 (x86_64)
  • os/type: linux
  • os/arch: amd64
  • go/version: go1.17.2
  • go/linking: static
  • go/tags: none

Using something like

rclone lsf GoogleDrive,root_folder_id=1FNQqadPB172XXXXXXXXXXXXXXXX:

should do it.

no need to be done in config?

That is equivalent to putting root_folder_id = 1FNQqadPB172XXXXXXXXXXXXXXXX in your config so you can do that if you prefer. You can also make an alias using that as the remote.

im trying doing this but seem not working,can u point out how to this on command?do it in config not really practical

I have tried this flag, and it work. Thanks for helping!

In case anyone looking for a more specific answer:
If u have a sharing link like this: https://drive.google.com/drive/folders/1FNQqadPB172XXXXXXXXXXXXXXXX?usp=sharing

the shared folder id would be: 1FNQqadPB172XXXXXXXXXXXXXXXX

then, you can copy this folder to your drive by this command:

rclone copy GD,root_folder_id=1FNQqadPB172XXXXXXXXXXXXXXXX: GD:/tmp/

where, "GD" is your rclone cloud driver name in your config.
And, if u want, u can add this flag to make a server side copy:

rclone copy GD,root_folder_id=1FNQqadPB172XXXXXXXXXXXXXXXX: GD:/tmp/ --drive-server-side-across-configs

Finally, u can find a copy of the shared folder at your google drive under path: /tmp/

Make sure your rclone is the latest version, i have tried to run this command on version 1.50.XX, and get this error

Failed to create file system for "GD,root_folder_id=1CdnAqP_ReCnTnbv1LnvXXXXXXXXX:": config name contains invalid characters - may only contain 0-9, A-Z ,a-z ,_ , - and space

but in the latest version, v1.58.1, this command works perfect. So please check your rclone version first.

anywhere i can find this command documentation?i cant find about it

--- for connection strings, https://rclone.org/docs/#connection-strings

--- connection string syntax is tricky, so need to post the exact command and full debug output, like so

rclone lsd gdrive,root_folder_id=redacted: -vv
DEBUG : rclone: Version "v1.58.0" starting with parameters ["rclone" "lsd" "gdrive,root_folder_id='redacted':" "-vv"]
DEBUG : Creating backend with remote "gdrive,root_folder_id='redacted':"
DEBUG : gdrive: detected overridden config - adding "{3IOt6}" suffix to name
DEBUG : fs cache: renaming cache item "gdrive,root_folder_id='redacted':" to be canonical "gdrive{3IOt6}:"
          -1 2021-09-09 19:36:45        -1 crypt
          -1 2022-01-12 13:38:48        -1 zork

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.