{"id":13128,"date":"2019-04-01T01:59:34","date_gmt":"2019-04-01T01:59:34","guid":{"rendered":"http:\/\/www.appservgrid.com\/paw92\/?p=13128"},"modified":"2019-04-01T01:59:34","modified_gmt":"2019-04-01T01:59:34","slug":"vi-vim-nano-emacs-my-favorite-command-line-editors-for-linux-whats-your-editor","status":"publish","type":"post","link":"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/04\/01\/vi-vim-nano-emacs-my-favorite-command-line-editors-for-linux-whats-your-editor\/","title":{"rendered":"Vi, Vim, Nano, Emacs &#8211; My Favorite Command Line Editors for Linux \u2013 What\u2019s Your Editor?"},"content":{"rendered":"<div id=\"attachment_17804\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Linux-Command-Line-Text-Editors.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-17804\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Linux-Command-Line-Text-Editors.png\" alt=\"Linux Command Line Text Editors\" width=\"720\" height=\"345\" aria-describedby=\"caption-attachment-17804\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-17804\" class=\"wp-caption-text\">Top 3 Linux Command Line Text Editors<\/p>\n<\/div>\n<p>Knowing how to fast and effectively\u00a0edit\u00a0files via command line is vital for every Linux system administrator. File edits are performed on a daily basis, whether it\u2019s a configuration file, user file, text document or whatever file you need to edit.<\/p>\n<p>This is why it is good idea to pick a favourite command line text editor and master it. It\u2019s good to know how to work with other text editors, but you should master at least one so you can perform more complex tasks when needed.<\/p>\n<p>In this tutorial, we are going to show you the most common command line text editors in Linux and show you their pros and cons.<\/p>\n<p><strong>Note<\/strong>\u00a0however that we will not cover a complete guide how to work with each one of them as this can be a complete other article with explanation.<\/p>\n<h3>1. Vi\/Vim Editor<\/h3>\n<p>First in our list is the infamous\u00a0<strong>Vi<\/strong>\/<strong>Vim<\/strong>\u00a0(<strong>Vim<\/strong>\u00a0comes from\u00a0<strong>Vi<\/strong>\u00a0improved).\u00a0This is a very flexible text editor that can perform many different operations on text.<\/p>\n<div id=\"attachment_17799\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Vi-Vim-Linux-Editor.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-17799\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Vi-Vim-Linux-Editor.png\" alt=\"Vi\/Vim Linux Editor\" width=\"893\" height=\"458\" aria-describedby=\"caption-attachment-17799\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-17799\" class=\"wp-caption-text\">Vi\/Vim Linux Editor<\/p>\n<\/div>\n<p>For example you can use regular expressions to replace text\u00a0snippets\u00a0in a file using vim. This of course is not the only benefit. Vi(m) provides an easy way to navigate between lines, words paragraphs. It also includes text highlighting.<\/p>\n<p><strong>Vim<\/strong>\u00a0may not be the most user friendly text editor, but it is often preferred by developers and Linux power users. If you want to install this command line text editor on your system, you can use the command associated with your OS:<\/p>\n<h4>Install Vi\/Vim Editor in Linux<\/h4>\n<pre>$ sudo apt-get install vim         [On Debian and its derivatives]\r\n# yum install vim                  [On RedHat based systems]\r\nOR\r\n# dnf install vim                  [On newer Fedora 22+ versions]\r\n<\/pre>\n<p>If you want to see our complete coverage of vi(m), please follow the links below:<\/p>\n<ol>\n<li><a href=\"https:\/\/www.tecmint.com\/vi-editor-usage\/\" target=\"_blank\" rel=\"noopener\">Learn and Use Vi\/Vim as a Full Text Editor in Linux<\/a><\/li>\n<li><a href=\"https:\/\/www.tecmint.com\/learn-vi-and-vim-editor-tips-and-tricks-in-linux\/\" target=\"_blank\" rel=\"noopener\">Learn \u2018Vi\/Vim\u2019 Editor Tips and Tricks to Enhance Your Skills<\/a><\/li>\n<li><a href=\"https:\/\/www.tecmint.com\/how-to-use-vi-and-vim-editor-in-linux\/\" target=\"_blank\" rel=\"noopener\">8 Interesting \u2018Vi\/Vim\u2019 Editor Tips and Tricks<\/a><\/li>\n<\/ol>\n<h3>2. Nano Editor<\/h3>\n<p><strong>Nano<\/strong>\u00a0is probably one of the most used\u00a0command line text editors. The reason for this is it\u2019s simplicity and the fact that it\u2019s preinstalled in most of the Linux distributions.<\/p>\n<div id=\"attachment_17800\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Nano-Editor-for-Linux.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-17800\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Nano-Editor-for-Linux.png\" alt=\"Nano Editor for Linux\" width=\"893\" height=\"458\" aria-describedby=\"caption-attachment-17800\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-17800\" class=\"wp-caption-text\">Nano Editor for Linux<\/p>\n<\/div>\n<p>Nano doesn\u2019t have vim\u2019s flexibility, but it will definitely do the work if you need to edit a large file. Actually\u00a0<strong>pico<\/strong>and\u00a0<strong>nano<\/strong>\u00a0are quite similar. Both have their command options displayed at the bottom so you can choose which one to run. Commands are completed with key combinations of\u00a0<strong>Ctrl<\/strong>\u00a0and a letter displayed at the bottom.<\/p>\n<p>Nano has the following features that you can use out of the box:<\/p>\n<ol>\n<li>Get Help<\/li>\n<li>Write out<\/li>\n<li>Justify<\/li>\n<li>Read File<\/li>\n<li>Where is (search)<\/li>\n<li>Previous page<\/li>\n<li>Next page<\/li>\n<li>Cut Text<\/li>\n<li>Uncut Text<\/li>\n<li>Cur Pos (Current position)<\/li>\n<li>Spell check<\/li>\n<\/ol>\n<h4>Install Nano Editor in Linux<\/h4>\n<pre>$ sudo apt-get install nano         [On Debian and its derivatives]\r\n# yum install nano                  [On RedHat based systems]\r\nOR\r\n# dnf install nano                  [On newer Fedora 22+ versions]\r\n<\/pre>\n<p>You can check our complete guide for editing files with Nano editor on this link:<\/p>\n<ol>\n<li><a href=\"https:\/\/www.tecmint.com\/rhcsa-exam-how-to-use-nano-vi-editors\/\" target=\"_blank\" rel=\"noopener\">How to Use Nano Editor in Linux<\/a><\/li>\n<\/ol>\n<h3>3. Emacs Editor<\/h3>\n<p>This is probably the most complex text editor in our list.\u00a0It\u2019s the oldest command line editor available for both Linux and UNIX\u00a0based systems.\u00a0<strong>Emacs<\/strong>\u00a0can help you be\u00a0more\u00a0productive by providing an integrated environment for different kinds of tasks.<\/p>\n<div id=\"attachment_17801\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Emacs-Editor-for-Linux.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-17801\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2015\/12\/Emacs-Editor-for-Linux.png\" alt=\"Emacs Editor for Linux\" width=\"893\" height=\"458\" aria-describedby=\"caption-attachment-17801\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-17801\" class=\"wp-caption-text\">Emacs Editor for Linux<\/p>\n<\/div>\n<p>At first the user interface may look somehow confusing. The good thing is that emacs has a very detailed manual that will help you with\u00a0file navigation, edits, customization, setting up commands.\u00a0Emacs is the ultimate tool used by advanced\u00a0<strong>*Nix<\/strong>\u00a0users.<\/p>\n<p>Here are some of the features that make it\u00a0the preferred choice over the previous editors we mentioned:<\/p>\n<ol>\n<li>Emacs server platform enables multiple hosts to connect to the same Emacs server and share the buffer list.<\/li>\n<li>Powerful and extensible file manager.<\/li>\n<li>Customization beyond a regular editor \u2013 as some say it\u2019s an OS within the OS.<\/li>\n<li>Commands customization.<\/li>\n<li>Can change to Vi(m) like mode.<\/li>\n<\/ol>\n<p>Emacs is a multi-platform editor and can be easily installed with the commands shown below:<\/p>\n<h4>Install Emacs Editor in Linux<\/h4>\n<pre>$ sudo apt-get install emacs         [On Debian and its derivatives]\r\n# yum install emacs                  [On RedHat based systems]\r\nOR\r\n# dnf install emacs                  [On newer Fedora 22+ versions]\r\n<\/pre>\n<p><strong>Note:<\/strong>\u00a0In\u00a0<strong>Linux Mint 17<\/strong>\u00a0I had to run the following command to complete the installation:<\/p>\n<pre>$ sudo apt-get install emacs23-nox\r\n<\/pre>\n<h3>Conclusion<\/h3>\n<p>There are other command line editors, but they barely even reach the functionality that the above 3 provide. Whether you are a Linux newbie or a Linux guru, you will most definitely need to learn at least one of the above mentioned editors. If we\u2019ve missed any command-line editor in this article, please don\u2019t forget to inform us via comments.<\/p>\n<p><a href=\"https:\/\/www.tecmint.com\/linux-command-line-editors\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Top 3 Linux Command Line Text Editors Knowing how to fast and effectively\u00a0edit\u00a0files via command line is vital for every Linux system administrator. File edits are performed on a daily basis, whether it\u2019s a configuration file, user file, text document or whatever file you need to edit. This is why it is good idea to &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/04\/01\/vi-vim-nano-emacs-my-favorite-command-line-editors-for-linux-whats-your-editor\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Vi, Vim, Nano, Emacs &#8211; My Favorite Command Line Editors for Linux \u2013 What\u2019s Your Editor?&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-13128","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/13128","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/comments?post=13128"}],"version-history":[{"count":1,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/13128\/revisions"}],"predecessor-version":[{"id":13129,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/13128\/revisions\/13129"}],"wp:attachment":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/media?parent=13128"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/categories?post=13128"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/tags?post=13128"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}