RClone Copy ignore extension but not name possible?

Hey all, I have been using RClone for a bit, but never in any advanced ways. I am still learning as I go per say. I have looked through the documentation and the forums and haven't found what I am looking for so far.

My goal is to be able to do a copy from my local directory structure on a Synology NAS > Google Drive except to skip files that have the same name but not necessarily the same extension. IE if there is a file that has the same name and date etc but the extension is the only difference then skip the copy of that file entirely. It seems like the Filtering options do the opposite of what I need, and my files change often so having a list of them specifically is not really an option.

For clarity, given in the following folder structure (sorry its a meh example) only file #3 would need to be copied to GDrive, as the first 2 files should be ignored as they exist on the remote directory even though one of them has a different extension.

Synology Drive/
Photos/Date of Shoot/
1 Mike_N_Jen_photos_20120913112205.JPG
2 Mike_N_Jen_photos_20120913112405.JPG
3 Mike_N_Jen_photos_20120913112605.PNG

Google Drive/ >
Photos/Date of Shoot/
1 Mike_N_Jen_photos_20120913112205.JPG
2 Mike_N_Jen_photos_20120913112405.PNG

Is this something that can be done with RClone? Thanks for any help in advance.

What is your rclone version (output from rclone version)

rclone v1.52.2

  • os/arch: linux/amd64
  • go version: go1.14.4

Which OS you are using and how many bits (eg Windows 7, 64 bit)

Synology NAS

Which cloud storage system are you using? (eg Google Drive)

Google Drive

You'll need to do a bit of scripting I think as rclone can't do this directly.

What you'd do is use rclone lsf -R to list the source and the destination then do a manual reconciliation ignoring the extensions. You'd create a list of files which needed to be transferred and feed this into rclone with --files-from.

Do do this entirely in rclone would need a "filename transformer" script which is something I've thought of but not implemented!

Copy that! thanks for the reply!

1 Like

can you make a eg.

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