[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#24025:
From: |
Leroy Harrill |
Subject: |
bug#24025: |
Date: |
Tue, 19 Jul 2016 08:11:09 -0400 |
I am not sure if this is a bug or not. Her is an example of my script that
I am running.
#!/bin/bash
rm -f x.txt
rm -f new_file
i=1
wc -l file1 | sed 's/file1//g' >> x.txt
x=$(<x.txt)
while [ $i -le $x ]
do
#echo "$i"
A=$( awk -v var="$i" 'NR==var {print}' file1)
#ack -k file1 file2 --match $A >> new_file
grep $A some_file.txt
((i++))
done
grep does not appear to be grepping inside of the while loop. When I
initialize a variable directly from the command line and write the same
script it works no problem, any help on this matter would be greatly
appreciated.
- bug#24025:,
Leroy Harrill <=