This is a discussion on less: display and quit if one screen within the Gentoo Linux Support forums, part of the Unix Operating Systems category; --> Hi all! There was this nifty thing that less would do on Suse, and I'm currently not able to ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hi all! There was this nifty thing that less would do on Suse, and I'm currently not able to reproduce on gentoo: Have less display the file and immediately quit if fits on one screen, mimicking cat. On gentoo, normally, less alyways takes up the entire screen, even if the file would fit on one screen (so cat would have been sufficient to display it). The less option --quit-if-one-screen comes close, but not close enough: Less quits immediately if the file would have fit on one screen, without diplaying it. How can I make less display-and-quit-if-one-screen? Thanks, Anno |
| |||
| Anno, Try this: less -FX <file name> Anno v. Heimburg wrote: > Hi all! > > There was this nifty thing that less would do on Suse, and I'm currently not > able to reproduce on gentoo: Have less display the file and immediately > quit if fits on one screen, mimicking cat. > > On gentoo, normally, less alyways takes up the entire screen, even if the > file would fit on one screen (so cat would have been sufficient to display > it). The less option --quit-if-one-screen comes close, but not close > enough: Less quits immediately if the file would have fit on one screen, > without diplaying it. How can I make less display-and-quit-if-one-screen? > > Thanks, > Anno |