Re: [Exim] Bug/Improvement in Readfile - Exim 4

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Marc Perkel
Ημερομηνία:  
Προς: exim-users
Αντικείμενο: Re: [Exim] Bug/Improvement in Readfile - Exim 4
Actually the whitespace was significant because I'm reading a file
that's being turned into a regular expression and the whitespace becomes
part of the regular expression test. It also added whitespace to the end
as well (whitespace at beginning of line ended up at the end of nested
sg) and the test for the "|" at the end failed.

Perhaps if there is a "\" at the end of a line that the white space at
the beginning of the next line should be trimmed?????

My 2 cents .....

Philip Hazel wrote:

>On Sun, 22 Dec 2002, Marc Perkel wrote:
>
>
>
>>I don't know if you know this or not but in your examples the white
>>space in front of the expressions here become part of the string that is
>>presented for sunstitution. On the third line of your example, the white
>>space in front of The ${readfile is appended to the beginning of the
>>expression. The indenting you use to (try to) make this look pretty is
>>affecting the results.
>>
>>
>
>I should have pointed that out. Sorry. I did remember to say the
>continuations weren't there, and I thought the comment text was pretty
>obvious. The layout I used was to try to explain how the item worked,
>not to make it look pretty. It's hard to make this stuff look pretty. :-)
>
>
>
>>>${sg{
>>> ${readfile{/file}{|}}
>>> }
>>> {\\|(\\||\$)}
>>> {$1}
>>>}
>>>
>>>
>
>Note, however, that leading whitespace *is* ignored after a
>continuation. So if you write an option such as
>
>  xxx = ${sg{\
>            ${readfile{/file}{|}}\
>            }\
>            {\\|(\\||\$)}\
>            {$1}\
>         }

>
>The space in front of ${readfile would *not* be significant. I guess
>that's why I didn't bother to mention this point.
>
>
>