I have a script to delete all folders created before past 2 days. Now, on Monday, it deletes just every folder from last week, which I do not want.
Is there an option to consider only weekdays for this command ? The whole script runs every day. I am using this:
find /my-folder/sub-folder/ -type d -ctime +1 | xargs rm -rf