How to specify a editor to open crontab file? “export EDITOR=vi” does not work

后端 未结 8 1891
感情败类
感情败类 2021-01-30 02:56

I\'m using Red Hat Enterprise Linux 5, and I want to set the vim editor to edit the crontab file.

If I run echo $EDITOR, I get vim. But when I run c

8条回答
  •  故里飘歌
    2021-01-30 03:24

    This worked for me :

    EDITOR="/usr/bin/vim"
    export EDITOR
    

    Add this to ~/.bash_profile or ~/.bashrc to enable this for current user.

提交回复
热议问题