Re: BASH Guru needed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



John P Verel wrote:


The problem is the pipe. It starts a subprocess, which is invisible to the parent process, i.e. the outer loop. This fragment will work:

echo ===========Loop 1==============
declare -a RULES
i=0
j=4
INFILE="/tmp/junkfile"
RULES=(`cat $INFILE`)
echo RULES ARRAY ${RULES[*]}



It's always nice to see compact shell scripts!


jch


-- Shrike-list mailing list Shrike-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/shrike-list

[Index of Archives]     [Fedora Users]     [Centos Users]     [Kernel Development]     [Red Hat Install]     [Red Hat Watch]     [Red Hat Development]     [Red Hat Phoebe Beta]     [Yosemite Forum]     [Fedora Discussion]     [Gimp]     [Stuff]     [Yosemite News]

  Powered by Linux