Thursday, May 25, 2017

grep - 'Grotty' man page messages


If I try to search within certain man pages using grep, I get several 'grotty' messages.


For example:


man mpv | grep dvdnav

results in:


mpv dvdnav://[longest|menu|title][/device] [options]
grotty: ():90690: character above first line discarded
grotty: ():90694: character above first line discarded
grotty: ():90698: character above first line discarded
grotty: ():90702: character above first line discarded
grotty: ():91895: character above first line discarded
grotty: ():91899: character above first line discarded
grotty: ():91903: character above first line discarded
grotty: ():91907: character above first line discarded
grotty: ():94450: character above first line discarded
grotty: ():94454: character above first line discarded
grotty: ():94458: character above first line discarded
│dvdnav:// │ dvdnav://menu │

What causes these messages and how do I prevent them?



I have no mpv installed, but this seems more a warning of grotty (the program that process man page sources to print it to standard output) probably coming from no-compliant man pages. Have you tried


man mpv 2> /dev/null | grep dvdnav

? This will redirect error and warnings from grotty to the sink, so that you should have a cleaner output.


Nevertheless, that error is probably a bug in the mpv man page (or in grotty, you never know).


No comments:

Post a Comment

11.10 - Can't boot from USB after installing Ubuntu

I bought a Samsung series 5 notebook and a very strange thing happened: I installed Ubuntu 11.10 from a usb pen drive but when I restarted (...