{"id":43394,"date":"2017-07-25T21:31:53","date_gmt":"2017-07-25T13:31:53","guid":{"rendered":"http:\/\/www.xyryd.com\/?p=43394"},"modified":"2019-04-29T16:50:29","modified_gmt":"2019-04-29T08:50:29","slug":"debian%e4%b8%8bcrontab%e9%bb%98%e8%ae%a4%e7%bc%96%e8%be%91%e5%99%a8nano%e5%88%87%e6%8d%a2%e5%88%b0vi-%e5%ae%9e%e4%be%8b%e6%95%99%e7%a8%8b","status":"publish","type":"post","link":"http:\/\/www.xyryd.com\/43394.html","title":{"rendered":"Debian\u4e0bcrontab\u9ed8\u8ba4\u7f16\u8f91\u5668nano\u5207\u6362\u5230Vi \u5b9e\u4f8b\u6559\u7a0b"},"content":{"rendered":"

Debian\u7cfb\u7edf\u5728\u4f7f\u7528crontab\u9ed8\u8ba4\u7684\u7f16\u8f91\u5668\u662fnano\uff0c\u7528\u8d77\u6765\u5f88\u4e0d\u65b9\u4fbf\uff0c\u8be5\u5982\u4f55\u8fdb\u884c\u5207\u6362\u5462\uff1f<\/p>\n

update-alternatives --config editor<\/pre>\n

There are 8 choices for the alternative editor (providing \/usr\/bin\/editor).
\nSelection? ? Path? ? ? ? ? ? ? ? Priority? Status
\n————————————————————
\n0? ? ? ? ? ? \/usr\/bin\/joe? ? ? ? 70? ? ? ? auto mode
\n* 1? ? ? ? ? ? \/bin\/nano? ? ? ? ? ? 40? ? ? ? manual mode
\n2? ? ? ? ? ? \/usr\/bin\/jmacs? ? ? 50? ? ? ? manual mode
\n3? ? ? ? ? ? \/usr\/bin\/joe? ? ? ? 70? ? ? ? manual mode
\n4? ? ? ? ? ? \/usr\/bin\/jpico? ? ? 50? ? ? ? manual mode
\n5? ? ? ? ? ? \/usr\/bin\/jstar? ? ? 50? ? ? ? manual mode
\n6? ? ? ? ? ? \/usr\/bin\/rjoe? ? ? ? 25? ? ? ? manual mode
\n7? ? ? ? ? ? \/usr\/bin\/vim.basic? 30? ? ? ? manual mode
\n8? ? ? ? ? ? \/usr\/bin\/vim.tiny? ? 10? ? ? ? manual mode
\nPress enter to keep the current choice[*], or type selection number: 7
\nupdate-alternatives: using \/usr\/bin\/vim.tiny to provide \/usr\/bin\/editor (editor) in manual mode.<\/p><\/blockquote>\n

\u8f93\u5165\u547d\u4ee4\u4e4b\u540e\uff0c\u63d0\u793a\u9009\u62e9\uff0c\u6839\u636e\u81ea\u5df1\u559c\u597d\u8fdb\u884c\u9009\u62e9\u5373\u53ef\uff0c\u8fd9\u91cc\u6211\u9009\u62e9\u7684\u662fVI\u7f16\u8f91\u5668\uff0c\u8f93\u51657\u3002
\n\u73b0\u5728crontab\u7f16\u8f91\u5668\u5df2\u7ecf\u53d8\u6210\u4e86VI\u3002
\n\u5982\u679c\u6ca1\u6709\u5207\u6362\u6210\u529f\uff0c\u8bf7\u624b\u52a8\u91cd\u542f\u4e00\u4e0b\u670d\u52a1\uff1a\/etc\/init.d\/cron restart<\/p>\n","protected":false},"excerpt":{"rendered":"

Debian\u7cfb\u7edf\u5728\u4f7f\u7528crontab\u9ed8\u8ba4\u7684\u7f16\u8f91\u5668\u662fnano\uff0c\u7528\u8d77\u6765\u5f88\u4e0d\u65b9\u4fbf\uff0c\u8be5\u5982\u4f55\u8fdb\u884c\u5207\u6362\u5462\uff1f update- […]<\/p>\n","protected":false},"author":1,"featured_media":43082,"comment_status":"open","ping_status":"closed","sticky":false,"template":"single-with-sidebar","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"aioseo_notices":[],"_links":{"self":[{"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/posts\/43394"}],"collection":[{"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/comments?post=43394"}],"version-history":[{"count":0,"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/posts\/43394\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/media\/43082"}],"wp:attachment":[{"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/media?parent=43394"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/categories?post=43394"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.xyryd.com\/wp-json\/wp\/v2\/tags?post=43394"}],"curies":[{"name":"wp","href":"http:\/\/api.w.org\/{rel}","templated":true}]}}