.adoc file to write documentation, it based on the
asciidoctor syntax, is possible through GUI use either
AsciiDocFX to see a preview. Therefore the
asciidoctor syntax is rendered/interpreted to be read it.
terminal what software - if exists - would do the same job about to render/interpret the
asciidoctor syntax to read it? I mean something like the execution of:
Consider as example: have a
html file and use
w3m to interpret and read it.
Therefore I want practically the same behavior like
man <commandname>, read a documentation with a pretty format.
You could write a script to do it
Render it to a temporary html file, then use
html2text to display the html file as text.
Is this what you’re looking for?
There is literally an asciidoc to nroff (manpage) translator.
I haven’t tried it.
I wrote a shell script 3 years ago to read a dump of HTML files from a wiki when my company transitioned into an outsource arrangement with a major customer…
# view some html crap with "w3m" and "less"
case $PLAT in
echo "don't be running that shit... shit, not here..."
IFS=$(echo -en "\n\b")
if [ ! -f $REND ] ; then
echo "w3m is not installed... install it?"
echo "e.g. "
echo " sudo apt install w3m"
echo " - or - "
echo " sudo dnf install w3m"
if [ "$#" -lt 1 ]; then
echo "Illegal number of parameters"
echo "e.g. "
echo " $PROG How_to_reboot_a_Zone_-_GooRoo.html"
echo " expecting a HTML file.... exiting"
$REND -dump $DOC | $PAGER
And because I use less as my pager, I can use vi navigation keys to navigate the output (and better yet “/” to search the HTML output).
Might use this.
It should fix an html file that is in too small a font to print by the usual method of making it a pdf file
I used it, with some mods.
I had this really useful website
and I wanted to print it.
The classic method using print or print to pdf failed… the fontsize was miniscule. You cant change fontsize in a .pdf file.
w3m rendered it to text, which was eminently printable.
Thanks to all for the replies and feedback, I will try to test each approach. A cold beer to you all.