--log-file only text archive named?

Hello everyone, I've been in the world of rclone for a while now, but now I'm trying to do a little more advanced things, but I have the following problem.

I want to copy from one folder to another, but copy each file only once, because I then move them from folder to folder and I don't want it to copy it again.

So it had occurred to me to use --log-file=no_copy.txt and with the option --exclude-from=no_copy.txt

But this doesn't work, since the text I get in no_copy is not the pure files but something like "INFO : XXX.jpg: Copied (server side copy)" and the exclude-from variable does not recognize that file name.

Does anyone know what flags or variables I should use so that when copying the rclone files it adds the pure names to the no_copy.txt file?

It is not something you can do with rclone alone. To generate and use your exclusion lists you will have to write a script to extract only file names from --log-file=no_copy.txt .

Thanks for the reply.

How could I create a script to extract the names between "INFO: "and ": Copied (server side copy)" into a file called no_copy_names.txt, for example?

Use whatever programming language or script you are comfortable with. You can find countless examples on Internet. As you do not provide any details what OS/system you are using it is impossible to give you more specific answer.

Oh, sorry.
I am using linux on debian 11.

I'm looking for examples but I'm going crazy


Thanks I will try it

1 Like

I have been able to do it the following way, with an LS to a file after the copies

rclone copy -P MY_DRIVE:"My Folder" MY_2_DRIVE:"My folder Backup --exclude-from="/Rclone SYNCS/no_copy.txt" -v --log-file="/Rclone SYNCS/log.txt" ; sleep 60 ; ls "My folder Backup" | grep -vE 'log.txt|no_copy.txt'>> "/Rclone SYNCS/no_copy.txt"

1 Like

Thanks for sharing how it can be achieved.

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