Warning: session_start(): open(/var/cpanel/php/sessions/alt-php74/sess_32f5252173279b07589d310452074dba, O_RDWR) failed: No such file or directory (2) in /home/xsofthost/public_html/help/wp-content/plugins/accelerated-mobile-pages/includes/redirect.php on line 358

Warning: session_start(): Failed to read session data: files (path: /var/cpanel/php/sessions/alt-php74) in /home/xsofthost/public_html/help/wp-content/plugins/accelerated-mobile-pages/includes/redirect.php on line 358
How To Install Use GNU Nano Text Editor and Commands In Linux OS

How to Install and use Nano Text Editor Commands in Linux

When working on the command line, quite often you will need to create or edit text files or any kind of file to edit. Two of the most powerful and popular command-line editors are Vim and Emacs. Both of them have a steep learning curve that can be intimidating to new users. For those who need a simple editor, there is nano. GNU nano is an easy to use command line text editor for Unix and Linux operating systems. It includes all the basic functionality you’d expect from a regular text editor, like syntax highlighting, multiple buffers, search and replace with regular expression support, spellchecking, UTF-8 encoding, and more.

When working on the command line, quite often you will need to create or edit text files or any kind of file to edit. Two of the most powerful and popular command-line editors are Vim and Emacs. Both of them have a steep learning curve that can be intimidating to new users. For those who need a simple editor, there is nano.

GNU nano is an easy to use command line text editor for Unix and Linux operating systems. It includes all the basic functionality you’d expect from a regular text editor, like syntax highlighting, multiple buffers, search and replace with regular expression support and more.

What is GNU Nano Editor

GNU nano is a one of the popular and easiest command line text editor used on many operating systems including Unix-based systems and BSD variants.

How to install GNU Nano Text Editor

Some OS distributions comes with Nano editor installed ,therefore install nano depends on OS.

Install GNU Nano Text Editor on Debian / Ubuntu

				
					sudo apt-get install nano
				
			

Install Nano Text Editor on CentOS / RHEL

				
					yum install nano
				
			

GNU Nano Text Editor Common Commands

To edit a file you can type the following command , in case the file not exists the Nono editor will create new file on save the file.
				
					nano sample.text
				
			

Here is some basic nano commands might help you while editing file:

  • CTRL + A :Jump to the beginning of the line.
  • CTRL + E :Jump to the end of the line.
  • CTRL + V :Scroll page up.
  • CTRL + Y :Scroll page down.
  • CTRL + W :Search for a specified phrase in your text. To search for the same phrase again press ALT + W.
  • CTRL + K :Cuts the entire selected line to the “cut buffer”.
  • CTRL + U :Pastes the text from the “cut buffer – Memory” into the selected line.
  • CTRL + J :Justifies the paragraph.
  • CTRL + _ :Go to specified line and column number.
  • CTRL + C : See where your cursor currently is.
  • CTRL + X :Exits Nano text editor. In case you made any changes to the file, it will prompt a save request.
Share on facebook
Share on twitter
Share on linkedin
Share on telegram
Share on whatsapp

Related Posts