The tag has no wiki summary.

learn more… | top users | synonyms

3
votes
3answers
92 views

Reopen a truncated file while following a file with less

Sometimes I am running a less +F on a log file, which I then truncate. I would like less to realize that the file has been truncated and start following the file as it is now. Currently, I am forced ...
4
votes
4answers
171 views

Adding tail behaviour where enter adds blank lines to less

I love less, which I can use to follow logs with the +F flag (or the ShiftF hotkey), search forwards and backwards, and generally move freely through the document. But there is one thing missing in ...
0
votes
1answer
83 views

Overwrote less command, how do I reinstall it?

I was trying to use the following command to pipe the results to less so that I could read a listing fully: ls -lh | less This, according to various sources pipe the contents to less and allow ...
4
votes
4answers
1k views

less with “update file” like functionality

I want to watch a file that gets overwritten every 5 minutes with less. How can I make less follow the new file descriptor instead of keeping the old one displayed? watch "cat file" won't do it ...
1
vote
2answers
44 views

How to make the 'less' command remember the last position of opened texts? [closed]

I like to read books in the terminal with the 'less' command. However when I stop reading, I'd like it to remember my last position so that I can resume with reading without having first to find where ...
4
votes
2answers
398 views

How to get less to seek faster with large log files?

I am often dealing with incredibly large log files (>3 GB). I've noticed the performance of less is terrible with these files. Often I want to jump do the middle of the file, but when I tell less to ...
2
votes
2answers
383 views

`less` not able to display special characters

I stumbled upon bad special characters in some manpages: If your terminal is a "true" auto-margin terminal (it doesnâ–’<80><99>t allow the last position on the screen to be updated ...
0
votes
1answer
278 views

Following a file mixed with grep to exclude lines

Basically I want to combine the function whereby you can Less a file and then Shift+F to follow the file, as you would do with Apache's access.log. However I would like the output to ignore/hide ...
2
votes
2answers
372 views

“Chop lines” in `less` isn't working

I'm doing: less -S my_database_dump.sql In order to see the files with the lines chopped (i.e. line wrapping.) But it's not working, the lines aren't being wrapped and I need to scroll horizontally ...
0
votes
1answer
67 views

How do you jump to a particular line when using less from the command line?

I want something like: less -j 4567 file.txt
14
votes
3answers
10k views

How to read backward from the end of file in less or more?

I've found one way so far: less +G filename, but it's scroll up only with up key line by line. What's more powerful less usages which provide scrolling by page, pattern search backward and so on?
2
votes
1answer
1k views

Less - Use PageUp/PageDown keys in Solaris

I have been away from Solaris for the last 5 years. I am use to use pageup and pagedown rather than b and f. Anyone know a simple way to make this work? My shell is /bin/tcsh ( Im QA so I cannot ...
14
votes
9answers
1k views

Is there a paging version of `watch`?

Under a UNIX shell, how can I get a similar effect to the watch command, but with paging so that I can scroll around in the output if it takes up more than one screen? In other words, I want a ...
1
vote
1answer
892 views

How can you set the -R in your LESS environment variable?

The question is based on this answer. How can you set the -R in your LESS environment variable?
1
vote
3answers
439 views

How can you color Apropos' output in Most/Less?

The following command gives me in the pager Most/Less man -k background The picture has everything in green, even descriptions. I would like to set them yellow. How can you have set the ...
1
vote
1answer
810 views

Unable to understand a line of Less_termcap

This problem is related to the thread. The line in my .zshrc export LESS_TERMCAP_mb=$'\E[01;31m' # begin blinking The following seems to mean \$ starts the expression ' -- ' says everything ...
4
votes
3answers
331 views

What do you do when a command floods your terminal with too much output?

I'm trying to solve a common annoyance: when SSH'd into remote servers I often do things that produce a lot more output than I'm expecting. For example, grepping a large log file with a pattern that ...
36
votes
2answers
9k views

Colors in bash after piping through less?

When I have dircolors defined life is full of... color. When I pipe ls through less to scroll around I lose the colors. Any suggestions? Thanks, -Mathew