I have a situation where I am deleting the crontab and then recreate it. So I do crontab -r and then crontab -e.
The problem I have is that crontab -e opens up nano, and I'd like a command line that can do crontab -e then send the F3 and F2 keys, which are for save and exit.
I need to this happen since I will be sending the commands via an ssh connection so nano will not be used interactively.
I am doing this to have crontab automatically create itself a brand new crontab file with all correct permissions and header.
Thank you ionut