خرید بک لینک

I wanted to save the output of man ffmpeg to a local file by ruing man ffmpeg > ffmpeg.man.txt.

When I opened that file in Geany full screen, there was line wrapping. I guessed it was because my terminal was at full screen width.

I halved my terminal's screen width and ran the command again. This time, I got:

Code:

$ man ffmpeg > ffmpeg.man.txt
<standard input>:1526: waing [p 14, 13.8i, div `an-div', 0.2i]: can't break line
$
I looked at man man which has

Code:

       MANWIDTH
              If  $MANWIDTH  is  set,  its  value is used as the line length for
              which manual pages should be formatted.  If it is not set,  manual
              pages will be formatted with a line length appropriate to the cur‐
              rent terminal (using an ioctl(2) if available, the value of  $COL‐
              UMNS,  or  falling back to 80 characters if neither is available).
              Cat pages will only be saved when the default  formatting  can  be
              used,  that  is when the terminal line length is between 66 and 80
              characters.
Then, I ran:

Code:

$ MANWIDTH=60 man ffmpeg > ~/Desktop/ffmpeg-man.txt
<standard input>:948: waing [p 12, 1.0i, div `an-div', 0.2i]: can't break line
<standard input>:1452: waing [p 19, 2.5i, div `an-div', 0.2i]: can't break line
<standard input>:1526: waing [p 20, 2.0i, div `an-div', 0.2i]: can't break line
$ MANWIDTH=70 man ffmpeg > ~/Desktop/ffmpeg-man.txt
<standard input>:948: waing [p 11, 6.2i, div `an-div', 0.2i]: can't break line
<standard input>:1452: waing [p 16, 13.3i, div `an-div', 0.2i]: can't break line
<standard input>:1526: waing [p 17, 10.2i, div `an-div', 0.2i]: can't break line
$ MANWIDTH=80 man ffmpeg > ~/Desktop/ffmpeg-man.txt
<standard input>:1526: waing [p 14, 5.5i, div `an-div', 0.2i]: can't break line
$ MANWIDTH=90 man ffmpeg > ~/Desktop/ffmpeg-man.txt
$
What does MANWIDTH do? MANWIDTH=90 does get rid of the screen messages but when I open the file generated by the last command above in Geany or Mousepad or Medit, there are several lines longer than 90 columns. Why is that?

برچسب: نویسنده: استخدام کار تاريخ: يکشنبه 8 فروردين 1395 ساعت: 12:38

صفحه بندی