Hello,
This is my first time working with FFAStrans and I'm still rather new to it. I was wondering if any of you knew a variable that would delete any file that was in specified folder.
the way i would use it would be following the workflow I made (see image below) and at the end of completing the workflow automatically direct it to delete the files in the "IN Folder" because I intend to leave a back-up in the folder anyways. Is that possible? Is it only possible with a ftp-server if so, got any pointers for me to get to that point or is it a variable in the ftp-server itself?
I'm just a young student, so excuse me if i'm asking a lot or if I missed a setting that would help me keep clean the "IN-folder" after it has done it's task.
[img]
How do you make a variable that deletes all files in a folder
Re: How do you make a variable that deletes all files in a folder
Hello Jojo, welcome to the forum and thanks to use FFAStrans !
It is really easy to do. If I understand well, you just want to delete your original files into your "Video-IN" folder once the workflow will be done.
You just have to create a "command-executor" node and put after the delivery folder. Edit it and write this command :
Your original files will be deleted
Other solution is possible too: Instead of do a backup of your original files (your backup node), you can move your original files into your backup folder.
So, instead of :
do :
To resume:
- you backup your original files AND you delete it at the end OR
- you don't backup original files but you move them at the end of workflow.
Hope it helps.
Cheers.
It is really easy to do. If I understand well, you just want to delete your original files into your "Video-IN" folder once the workflow will be done.
You just have to create a "command-executor" node and put after the delivery folder. Edit it and write this command :
Code: Select all
%comspec% /c "del /f /q "%s_original_full%""
Other solution is possible too: Instead of do a backup of your original files (your backup node), you can move your original files into your backup folder.
So, instead of :
Code: Select all
%comspec% /c "del /f /q "%s_original_full%""
Code: Select all
%comspec% /c "move "%s_original_full%" "path of your backup folder""
- you backup your original files AND you delete it at the end OR
- you don't backup original files but you move them at the end of workflow.
Hope it helps.
Cheers.
Re: How do you make a variable that deletes all files in a folder
Hi JoJo,
Be aware that running a dos command like "del" and "move" if "%s_original_full%" points to an FTP-source, will not work yet. Currently the "%s_original_full%" only stores the full path to a file, not credentials needed to delete or move a file from FTP.
-steinar
Be aware that running a dos command like "del" and "move" if "%s_original_full%" points to an FTP-source, will not work yet. Currently the "%s_original_full%" only stores the full path to a file, not credentials needed to delete or move a file from FTP.
-steinar
Re: How do you make a variable that deletes all files in a folder
Hi JoJo,
be aware of using "MOVE" - especially when moving files from one drive to another. Use one node with "COPY (originalFile to destination / Backup-Disk)" and a following node with "DEL (OriginalFile from source-Disk)". You can use "MOVE" when you leave the file on the same drive, just moving it to another directory.
In your workflow there is also an "A/V-Media"-Node - maybe you just do not need it. If you need it, add a "Channel-Mapper"-Node to specify only the audio-channels you need.
After your destination-"FOLDER"-Node add a command-executioner-Node with the "DEL"-Command Momocampo mentioned.
just my 2 cents
be aware of using "MOVE" - especially when moving files from one drive to another. Use one node with "COPY (originalFile to destination / Backup-Disk)" and a following node with "DEL (OriginalFile from source-Disk)". You can use "MOVE" when you leave the file on the same drive, just moving it to another directory.
In your workflow there is also an "A/V-Media"-Node - maybe you just do not need it. If you need it, add a "Channel-Mapper"-Node to specify only the audio-channels you need.
After your destination-"FOLDER"-Node add a command-executioner-Node with the "DEL"-Command Momocampo mentioned.
just my 2 cents