[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug-recutils] Value Expressions
From: |
Michał Masłowski |
Subject: |
Re: [bug-recutils] Value Expressions |
Date: |
Thu, 06 Sep 2012 21:47:10 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) |
> Yes, but we still have to figure out a way to make the value of other
> fields available to the filter, i.e. how to pass the existing value of
> another field to sed, or some composition of fields?
We could use environment variables, e.g. adding an argument to set a
named variable to the result of a FEX. (There are obvious alternatives
like not passing other fields or passing the whole record in stdin, they
won't help with the company email example.)
Adding company email addresses could be done as:
recset -f Email --define-variable FIRST_NAME=FirstName \
--define-variable LAST_NAME=LastName --define-variable COMPANY=Company \
--add-filtered 'echo address@hidden'
This might be too much to type. Automatic variable assignments could
make it shorter, although they won't work with more complex FEXes and
could conflict with other variables used in the script called.
pgpcM4LCbBFci.pgp
Description: PGP signature
- Re: [bug-recutils] Value Expressions, Jose E. Marchesi, 2012/09/03
- Re: [bug-recutils] Value Expressions, John Darrington, 2012/09/04
- Re: [bug-recutils] Value Expressions, Jose E. Marchesi, 2012/09/04
- Re: [bug-recutils] Value Expressions, John Darrington, 2012/09/06
- Re: [bug-recutils] Value Expressions, Jose E. Marchesi, 2012/09/06
- Re: [bug-recutils] Value Expressions, Michał Masłowski, 2012/09/06
- Re: [bug-recutils] Value Expressions, Jose E. Marchesi, 2012/09/06
- Re: [bug-recutils] Value Expressions,
Michał Masłowski <=
- Re: [bug-recutils] Value Expressions, Jose E. Marchesi, 2012/09/07