Differences

This shows you the differences between two versions of the page.

Link to this comparison view

less [2013/05/02 15:35] (current)
Line 1: Line 1:
 +====== less ======
  
 +=== Arguments ===
 +
 +  * **''​-F''​** - exit if the entire file is display on the first screen
 +  * **''​-i''​** - ignore case on searches
 +  * **''​-J''​** - Displays an asterisk next to each matching line of a search (but also adds a blank column on the left)
 +
 +=== Keyboard commands ===
 +
 +Where **''​N''​** is a number (integer).
 +
 +  * **''​F''​** - scroll forward, and watch the file for new lines (similar to ''​tail -f''​)
 +  * **''​g''​** - jump to first line
 +  * **''​Ng''​** - jump to line #
 +  * **''​G''​** - jump to last line
 +  * **''​N%''​** - jump to ''​N''​ percent of the file (fex: 25%)
 +  * **''&<​pattern>''​** - only show lines that match ''<​pattern>''​ (similar to grep); use ''&''​ to remove filter
 +  * **''​=''​** - print some info about the file
 +  * **''​v''​** - edit the same file using the ''​VISUAL''​ environment variable as your editor
 +  * **''​!<​string>''​** - execute ''<​string>''​ and print results (fex: ''​!ls''​)
 +  * **''​s<​filename>''​** - save piped output to ''<​filename>''​