Sample Header Ad - 728x90

Customize the man command's status prompt to show percentage read

8 votes
1 answer
882 views
I like the man command's status prompt to be customized. The default as picked from its own man page is like this, Manual page name(sec) line x But, having it show me the percentage of contents read is my preference. So I set the environment variable that controls the prompt, MANLESS as, export MANLESS='?pt%pt \%: ' The prompt is empty. I put -P in the front as, export MANLESS='-P?pt%pt \%: ' No progress, now the prompt only contains -P. So, I directly set it for every invocation using the -r option, man -r '?pt%pt \%: ' less That too didn't help. But, this same prompt when set to LESS env. variable as export LESS="-P?pt%pt \%" Every direct invocation of less is showing the desired prompt as x %. It is only when less pager is called through man, it does not work.
Asked by Saravana (193 rep)
Oct 13, 2024, 04:42 PM
Last activity: Oct 14, 2024, 05:00 PM