less is a terminal pager program used to view (but not change) the contents of a text file one screen at a time. Questions regarding the use of less in Ubuntu should go by this tag

learn more… | top users | synonyms

1
vote
1answer
20 views

How to get the long 'less' prompt with sudo?

I have added the following to my user's .bashrc file to get a longer prompt in less: export LESS="-M" This is added to the root user's .bashrc file as well, so when I sudo bash to get a root shell, ...
0
votes
1answer
103 views

sublime text 2 and less2css issue

On ubuntu 14.04 I have installed Sublime Text 2 and a plugin named less2css. When I try to save, for example MAIN.less, file is saved, but isn't compiled into MAIN.css. Sublime alerted me that ...
2
votes
2answers
237 views

How do I make `less` output colors?

When I run a program (for example grep or ls) without a pager, its output is colored. However when I run it piping its output to less, no colors are shown. For example, this command outputs colored ...
0
votes
1answer
42 views

less.vim not working on my Ubuntu 12.04 lts

I found many sites saying that vim can be used as a pager like less with syntax highlighting. So to make it work I added this line to my .bash_aliases file: alias vless='vim -u ...
2
votes
1answer
120 views

Less output does not show output in terminal after quitting it

Previously, if I ran something | less, and then press q, it used to return me to the prompt with the output of less still visible. $ seq 1 100 | less 1 2 3 4 :q $ <prompt here. I can still see the ...
0
votes
0answers
64 views

Terminator - Bash character encoding - problem visualizing content of some files

I'm using Terminator to manage several bash shells. If I print the content of some files, some characters are bad displayed. Even if the character encoding is setted to UTF-8. Below there is the ...
2
votes
2answers
359 views

How to use pygmentize automatically with less [duplicate]

I found pygmentize thanks to this answer, but it would be great if it could be used to highlight text with less or maybe replace the command. Is there a way to do that? Thanks in advance.
7
votes
1answer
1k views

How can I stop less from storing history?

Every time I search for a term in less, it stores my search in the file .lesshst. How can I stop this behavior?