Skip to content

Commit

Permalink
fixed grep line count by using json output instead
Browse files Browse the repository at this point in the history
  • Loading branch information
burnzy committed May 15, 2016
1 parent a4b28a8 commit aade780
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions jmeter-ec2.sh
Expand Up @@ -289,11 +289,11 @@ function runsetup() {
# Update progress bar
progressBar $countof_instanceids $count_passed
status_check_count=$(( $status_check_count + 1))
count_passed=$(aws ec2 describe-instance-status --instance-ids ${attempted_instanceids[@]} \
count_passed=(`aws ec2 describe-instance-status --instance-ids ${attempted_instanceids[@]} \
--region $REGION \
--output text \
--query 'InstanceStatuses[].InstanceStatus.Details[].Status' | grep -c passed)
sleep 1
--output json \
--query 'InstanceStatuses[].InstanceStatus.Details[].Status' | grep -c passed`)
sleep 1
done
progressBar $countof_instanceids $count_passed true
echo
Expand Down

0 comments on commit aade780

Please sign in to comment.