The current cron job shell script have a bug. That is if i use exit
function in the script, For example
Then it's not execute below command
To solve the problem, Execute the user's script in a sub shell. Here is the code (Please Fix it in the next update)
#!/bin/bash
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin
export PATH
(
$USER'S_CODE_HERE
)
echo '----------------------------------------------------------------------------'
endDate=`date +"%Y-%m-%d %H:%M:%S"`
echo "★[$endDate] Successful"
echo '----------------------------------------------------------------------------'