This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: cygwin bash script suddenly can't find ls, grep
- From: LMH <lmh_users-groups at molconn dot com>
- To: cygwin at cygwin dot com
- Date: Tue, 14 Oct 2014 16:54:28 -0400
- Subject: Re: cygwin bash script suddenly can't find ls, grep
- Authentication-results: sourceware.org; auth=none
- References: <5439C59F dot 5060308 at molconn dot com> <5439C8A6 dot 5020605 at cornell dot edu> <5439CB8F dot 9000708 at molconn dot com> <m1dedl$mea$1 at ger dot gmane dot org>
Thorsten Kampe wrote:
> * LMH (Sat, 11 Oct 2014 20:30:07 -0400)
>> Good Lord, I guess I wasn't thinking very clearly trying to use
>> PATH as
>> a variable for something else. I changed to,
>>
>> FILE_DIR=$(ls -d './'$SET'/'$FOLD'/'$FOLD'_anneal/'$PARAM_SET'/'$AN_SET)
>> echo $FILE_DIR
>>
>> FILE_LIST=($(ls $FILE_DIR'/'*'out.txt' ))
>> echo ${FILE_LIST[@]}
>
> That looks pretty ugly. You probably can replace all that with
>
> FILE_LIST=(./$SET/$FOLD/$FOLD_anneal/$PARAM_SET/$AN_SET/*out.txt)
>
> Thorsten
>
>
> --
> Problem reports: http://cygwin.com/problems.html
> FAQ: http://cygwin.com/faq/
> Documentation: http://cygwin.com/docs.html
> Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
>
>
Thank you for the suggestion. I have mad an additional post in response
to the previous message that addresses your suggestion as well.
LMH
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple