0

I wonder how to edit crontab with nano editor for super user via sudo. I used the following command but it didn't work. crontab was open but it was not a nano editor.

export EDITOR=nano
sudo crontab -e  
2

Try with sudo -E crontab -e to preserve the environment variable EDITOR you are setting in your own session.

  • Or sudo EDITOR=nano crontab -e. – joan Aug 10 '17 at 10:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.