Re: install the Korn SHELL program

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

 



최용주 wrote:
> I installed the 'ksh', so when I type the command in my terminal. It echoes the '$'.
>
>
>   
Save the attached and make it executable and try it....
#!/bin/ksh
rm *.tmp
rm *.lst
for i in *.type3; do
echo $i >> name.tmp
gawk 'END {print NR}' $i >> nrow.tmp
done

paste name.tmp nrow.tmp > filename.tmp
gawk '{ if ( $2 < 1) print $1}' filename.tmp >> final.lst

for ii in $(cat final.lst) ;do
rm $ii
done

rm *.tmp
rm *.lst
for i in *.type4; do
echo $i >> name.tmp
gawk 'END {print NR}' $i >> nrow.tmp
done

paste name.tmp nrow.tmp > filename.tmp
gawk '{ if ( $2 < 1) print $1}' filename.tmp >> final.lst

for ii in $(cat final.lst) ;do
rm $ii
done


rm *.tmp
rm *.lst
for i in *.type2; do
echo $i >> name.tmp
gawk 'END {print NR}' $i >> nrow.tmp
done

paste name.tmp nrow.tmp > filename.tmp
gawk '{ if ( $2 < 1) print $1}' filename.tmp >> final.lst

for ii in $(cat final.lst) ;do
rm $ii
done

rm *.tmp
rm *.lst
for i in *.type1; do
echo $i >> name.tmp
gawk 'END {print NR}' $i >> nrow.tmp
done

paste name.tmp nrow.tmp > filename.tmp
gawk '{ if ( $2 < 1) print $1}' filename.tmp >> final.lst

for ii in $(cat final.lst) ;do
rm $ii
done
-- 
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux