bug-a2ps
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

a2ps.cfg options


From: Carl Lowenstein
Subject: a2ps.cfg options
Date: Wed, 17 Oct 2007 20:47:25 -0700

GNU a2ps, version 4.13

I have been trying for some time today to make my local ~/.a2ps/a2psrc
produce printed output with the header date stamp looking like
"2007-10-17 20:21" for the file date, and the footer date stamp
looking like "2007-10-17 Wednesday" for the local date.  According to
section 3.2.3 of the manual, I need to use the escapes %D{} and $D{}
to format with strftime(3).

I found after some experimentation that blank spaces in the argument
list enclosed in {} brackets must be escaped.  Thus the resulting
a2psrc file looks like this (original lines copied from /etc/a2ps.cfg
and commented out).  Note the "\ " in the last line.
- - - - - - - -
# Left part of the title is the mod. date of the file
# or empty is there is a tag2
#Options: --left-title='#?2||$e $T|'
Options: --left-title='#?2||$D{%F} $T|'

# If in landscape, print date on the left hand side
# If portrait, then print date on recto, and sheet # on verso
#Options: --left-footer=#?l!%E!#?v|%E|%s./%s#|!
Options: --left-footer=#?l!%D{%F\ %A}!#?v|%D{%F\ %A}|%s./%s#|!
- - - - - - - -

The necessity for escaping the space should be mentioned somewhere in
the documentation.  Without the escape, the rather misleading error
message is:
" a2ps.bin: left footer: missing `!' for #?l escape "

    carl
-- 
    carl lowenstein         marine physical lab     u.c. san diego
                                                 address@hidden




reply via email to

[Prev in Thread] Current Thread [Next in Thread]