/ tech-note

Don't append `.sh` extension to your cron script

Having created a .sh script you want to run periodically, and put it in /etc/cron.daily/, you still find it not working😰? The potential problem might come from the file extension.

You should NOT append the .sh extension🙅🏻 So just remove it and test it again with run-parts --test /etc/cron.daily.

Or more correctly, your script name should consist only of lowercase, uppercase, hyphen, and underscore.

If your script can be found there, it will work properly🐒

The source: