How to Edit Your Crontab Using Vim

For the best reading experience, I recommend you view this content natively at: How to Edit Your Crontab Using Vim.





If you’re a vim user like I am and you run crontab -e and get dropped into nano, you’re likely to make the same face as a baby eating a lemon.



A baby eating a lemon



Not fun, but there’s a fix.



Update your shell configuration file (.bashrc, .zshrc, .profile, whatever), to include the following:




alias crontab=”export VISUAL=vim; crontab”



Then you can simply run the command normally to edit your crontab with vim.



crontab -e



No more nano, and good riddance.


Read or comment at How to Edit Your Crontab Using Vim.

 •  0 comments  •  flag
Share on Twitter
Published on November 21, 2017 15:47
No comments have been added yet.


Daniel Miessler's Blog

Daniel Miessler
Daniel Miessler isn't a Goodreads Author (yet), but they do have a blog, so here are some recent posts imported from their feed.
Follow Daniel Miessler's blog with rss.