Does rclone support server side hardlinks on gsuite? E.g. I can create a file on gsuite and shift+z to create a hardlink of the file somewhere else including linking across drive <-> team drives. Is there a way to achieve this with rclone?
Rclone will correctly deal with files like that, however…
What would you think the user interface should be?
I would imagine extending the "-l/--links" flag and creating another flag for creating links:
Usecase "create link if source is link and target is within the path that is getting copied"
if copying and file is a link,
and link points to a file within the path that is currently getting copied
and follow symlinks is not enabled
then create a link on remote if the service allows linking.
Otherwise create a .rclonelink as implemented currently.
rclone copy --links remote:/path/to/file remote:/path/to/target
Usecase "create links for file(s)"
if copying and create links flag is enabled,
then create a link on the remote if the service allows linking.
Otherwise create a .rclonelinks (or maybe nothing).
rclone copy --create-links remote:/path/to/file remote:/path/to/target
(where target is a link to file)
The second use case is the most important one though, as it at least allows such a feature and some scripting could probably achieve much of desired need as in first usecase. Would save me 50+ tb
edits: wasn't easy to do it without errors on the go Prob more here, but hey, at least a start.
It might make sense to take a leaf from rsync's book here
--link-dest=DIR This option behaves like --copy-dest, but unchanged files are hard linked from DIR to the destination directory. The files must be identical in all preserved attributes (e.g. permissions, possibly ownership) in order for the files to be linked to‐ gether. An example: rsync -av --link-dest=$PWD/prior_dir host:src_dir/ new_dir/