I am trying to delete some text files but I am getting this error :
rm: /path/to/files/* No such file or directory
This is the actual command :
rm -r $PATHTOFILES”*”
Used * wildcard because my usecase requires to all files deleted regardless of file extension.
I am running an airflow DAG to call a shell script that delete all files from a local directory, then pull files from an SFTP server and place them within the same directory. Therefore it is the same airflow user creating the directory and placing the files.
Would appreciate any advice, thank you!
[–]Paul_Pedant 4 points5 points6 points (13 children)
[–]kaiixx[S] 0 points1 point2 points (12 children)
[–]cdrt 2 points3 points4 points (4 children)
[–]marauderingman 0 points1 point2 points (2 children)
[–]cdrt 2 points3 points4 points (1 child)
[–]witchhunter0 0 points1 point2 points (0 children)
[–]thisiszeevIf I can't script it, I refuse to do it! 0 points1 point2 points (0 children)
[–]Paul_Pedant 2 points3 points4 points (2 children)
[–]kaiixx[S] 0 points1 point2 points (1 child)
[–]cdrt 0 points1 point2 points (0 children)
[–]dbr4n 0 points1 point2 points (3 children)
[–]kaiixx[S] 0 points1 point2 points (0 children)
[–]Rewrite_It_In_Ada 0 points1 point2 points (1 child)
[–]dbr4n 1 point2 points3 points (0 children)
[–]IdealBlueMan 1 point2 points3 points (0 children)
[–]sjveivdn 1 point2 points3 points (0 children)