On Tue, Jun 20, 2006 at 11:37:09AM +0200, oopla wrote:
>  Now, if we had e.g. -b meaning 'use basename(filename)', sample use above 
>  would allow to have 
> 
>  $ ./faxinfo -b ... : 
>  <tr><th><a href="/some/other/path/fax07138.tif">fax07138.tif</a>...

ok, my current version goes like:

$ ./faxinfo -h
./faxinfo: invalid option -- h
Usage: faxinfo [-D] [-b][-n] [-S fmt] [-s fmt] [-e fmt] [-E fmt]

        -n      Print FAX pathname
        -b      Print FAX basename (does _not_ imply -n)
        -C d    Quoted CSV-style output with <d> as the deliminator
        -c d    CSV-style output with <d> as the deliminator
        -r      raw format - values outputed with no names
  Raw format options:
        -S fmt  Use fmt for the fax start format
        -s fmt  Use fmt for the field start format
        -e fmt  Use fmt for the field end format
        -E fmt  Use fmt for the fax end format
        -D      Debug - print on stderr SseE fmt strings

Exit codes are: 
  0:ok
  1:"Could not open..."
  2:"Does not look like a facsimile"
I've applied patches 1,2,-format-3b,-format-4,-format-shortcuts-1b from
http://bugs.hylafax.org/show_bug.cgi?id=786 and the attached patch, to 
faxinfo.c++ as in 4.3.0.

So my patch adds -b, a fix to escapedString(), non-0 exit code on error,
and -D. Didn't attempt further fmt string sanitizing other than in prev msg.

Seems to WFM so far and does what I need - should upstream come up with 
better solution I'll likely sync with that :)

Reg. embedding +'local' infos in .tif, hence due enhancement in faxinfo to
retrieve such, I'll file another bugrep for hylafax-server.


thanks

-- paolo

Attachment: faxinfo.c++_4p-oo.diff.gz
Description: Binary data

Reply via email to