make a pdf with txt in terminal
to print the manual page of a command in pdf, i will type in terminal (for eg. with the avconv command)
Code:
man -t avconv | ps2pdf - > avconv.pdf
now i want to print the list of audio codecs used by avconv in pdf, that is
Code:
avconv -codecs | grep A
how can i manage this ?
Re: make a pdf with txt in terminal
I guess there are many ways to do it. I usually filter text through mpage(1) like this
Code:
echo some text|mpage -2|ps2pdf
Re: make a pdf with txt in terminal
I use a HTML -> PDF converter called mPDF for generating quotes for my clients. You could try going that route.
Re: make a pdf with txt in terminal
Quote:
Originally Posted by
schragge
I guess there are many ways to do it. I usually filter text through
mpage(1) like this
Code:
echo some text|mpage -2|ps2pdf
thx for your response !
but i didnt succeed that way....
Code:
mpage 'avconv -codecs' -2 | ps2pdf - > test.pdf
returns
Code:
mpage: cannot open avconv -codecs
i did it graphically with gedit but hey this is not a geekclass solution lol
Re: make a pdf with txt in terminal
No, you should did it like this
Code:
avconv -codecs|mpage -2|ps2pdf - >test.pdf
Re: make a pdf with txt in terminal
yeah great thx !
Code:
avconv -codecs|grep A | mpage -2|ps2pdf - >test2.pdf
worked as well