[pmwiki-users] Command line pretty-print PmWiki pages
eemeli at gmail.com
Thu Jul 30 02:53:10 CDT 2009
In case this might be of use to anyone, I use the following sed
scripts for pretty-printing PmWiki pages to the command line (defined
alias pmf="sed 's/^text=/text=\n/;s/%0a/\n/g;s/%3c/</g;s/%25/%/g'"
alias pmp="sed '
s/^\([^=]\+\)=/\1 | /
"pmf Group.PageName" will print all of the fields of the page, but
with the urlencoded newlines, < and % characters translated to their
"pmf Group.PageName" will reformat the printout to ignore diffs and
other non-current data, print the header fields first and a bit more
clearly formatted, followed by the text with the decoded characters.
There may well be a more elegant way of doing this, but at least the
above works for me. Anyone else have command line scripts that they
use with PmWiki?
More information about the pmwiki-users