The solution still using Init variable file list, to get the file list in the folder source. But we can't use action move files directly, since for multiple files, we have to mention a directory, which mean the source file name and destination file name will be the same. To make it different in each individual files and without looping action move files, we can simply use execute command, mv. (no root). We need to loop the list first in script, creating the lines of command before passing to execute command.
Code: Select all
line = newList();
target = "/storage/emulated/0/data/";
for(i in files)
addElement(line, "mv '" + i + "' '" + replaceAll(i, "/.*/(.*)(\\..*)", "{target}$1_MOVED$2'") );
line store every command to move the file. Target is the path of destination. The loop add all element and its renamed version to the line. The renamed name is found by using replaceAll regex, added with _MOVED before the extention.
After this script, add Execute command and use
{line,listformat}
in the command field.