X-Spam-Check-By: sourceware.org
X-Authenticated: #36912987
Message-ID: <45A5292A.20606@gmx.de>
Date: Wed, 10 Jan 2007 18:58:02 +0100
From: Saro Engels <ps_ml@gmx.de>
User-Agent: Thunderbird 1.5.0.9 (Windows/20061207)
MIME-Version: 1.0
To: cygwin@cygwin.com
Subject: Re: cygwin-email utility clipping attached zips
References: <006701c734d6$d8531e00$a501a8c0@CAM.ARTIMI.COM> <45A520B8.7090802@wi.rr.com> <45A52736.2040009@gmx.de>
In-Reply-To: <45A52736.2040009@gmx.de>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Y-GMX-Trusted: 0
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

Saro Engels schrieb:
>> I spoke with Dean as well, the author, and he advised the same.  I 
>> wrote a little script that accomplishes what I need, and wanted to 
>> share it, pasted in line below:
>>
>> email.bash
>> #!/bin/bash
>> export file=""
>> for x in *.pdf; do
>>         export file=$file,$x
>> done
>> echo $file
>> email user@domain.com -s test -a $file < sample.txt
>>
> 
> I think you should better use the following thing:
> $ file=*.pdf; file=`echo $file | sed "s/ /,/"`
> $ echo $file
> $ email user@domain.com -s test -a $file < sample.txt
> 
> your code will return a list starting with a comma:
> $ echo $file
> ,file1.pdf,file2.pdf,file3.pdf...
> 
> See it as an improvement - I needed quite long for that part.
> SE

I wasn't right:
It should be:
$ file=*.pdf; file=`echo $file | sed "s/ /,/g"`
$ echo $file
$ email user@domain.com -s test -a $file < sample.txt

;-)
SE


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

