Use of variable or system maintained field in config file printer definition?

Laura Brody laura.k.brody at gmail.com
Sat Aug 11 11:55:03 PDT 2018


If you send the output through a pipe, rather than direct to a filename,
the shell gets involved and will expand environment variables:

printer7=txt,nocodes,|cat >/home/$LOGNAME/report.txt

This is one of the rare cases where a "useless use of cat" isn't so useless.

Laura Brody


On Sat, Aug 11, 2018, 2:14 PM James Flanagan via Filepro-list <
filepro-list at lists.celestial.com> wrote:

> Filepro 5.7.00.09D4
> FreeBSD 10.3
>
> What I am trying to is something like the following so that printer’s
> output destination is controlled by the value of a variable.  Otherwise I
> would need to define a separate printer for each user, which is too
> unwieldily.  And yes, I realize, I could print to a single destination,
> such as /tmp and then use a system command to move the file with
> appropriate variable right afterwards (which is actually what I am doing
> now).  However, if possible, I would much prefer to be able to have the
> printer conditionally put the output directly where it is intended to go,
> all in a single step.
>
> Is this possible in Filepro?  The 2 examples below do NOT work and the
> variables are treated as actual values, and not what the variable
> represents.
>
> printer7=txt,nocodes,>/home/@id/report.txt
>
> Or
>
> printer7=txt,nocodes,>home/$LOGNAME/report.txt
>
> Thank you very much, in advance.
>
>
> James Flanagan
> Flantec.com <http://flantec.com/>
>
> email:  James at Flantec.com <mailto:James at Flantec.com>
> mobile: 760-458-8498
> home:   219-221-6219
> text:           7604588498 at txt.att.net <mailto:7604588498 at txt.att.net>
>
> Skype:  Flantec
> ichat:  James at Flantec.com <mailto:James at Flantec.com>
>
> home:   1901 Cidermill Road
>                 Michigan City, IN 46360
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> http://mailman.celestial.com/pipermail/filepro-list/attachments/20180811/109c481f/attachment.html
> >
> _______________________________________________
> Filepro-list mailing list
> Filepro-list at lists.celestial.com
> Subscribe/Unsubscribe/Subscription Changes
> http://mailman.celestial.com/mailman/listinfo/filepro-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.celestial.com/pipermail/filepro-list/attachments/20180811/dc9b14f1/attachment.html>


More information about the Filepro-list mailing list