simple question:
10 4 * * * rm -rf ~/code/rehlds/build/ && ~/code/rehlds/build.sh --compiler=gcc --jobs=4 > /dev/null 2>&1
I checked an there is no /build folder which indicates that the build.sh did not execute.
crontab -e
10 4 * * * rm -rf ~/code/rehlds/build/ && ~/code/rehlds/build.sh --compiler=gcc --jobs=4 > /dev/null 2>&1
pgrep cron 658 1232359
so here I can see it was run
sudo grep CRON /var/log/syslog
Dec 8 04:10:01 xxxx CRON[1190963]: (xxx) CMD (rm -rf ~/code/rehlds/build/ && ~/code/rehlds/build.sh --compiler=gcc --jobs=4 > /dev/null 2>&1)
my job ran, but no compiling, that cronlog file is empty.
CMD (./code/rehlds/build.sh --compiler=gcc --jobs=4 &> ./cronlog)
dev/nulland run again – Romeo Ninov Dec 08 '22 at 11:5810 4 * * * rm -rf ~/code/rehlds/build/ && ~/code/rehlds/build.sh --compiler=gcc --jobs=4 > ~someloglike this? will it create thissomelogif not existing? – eetzt Dec 08 '22 at 11:59>/full/path/log 2> /full/path/errto generate log for STDOUT and for STDERR. And use absolute paths – Romeo Ninov Dec 08 '22 at 12:08* * * * * touch ./testfile &> ./testlog– eetzt Dec 08 '22 at 12:32somecmd > ~/rehldslog 2>&1. in the logs i can see(CRON) info (No MTA installed, discarding output)and somecmd did not run – eetzt Dec 10 '22 at 12:31