#!/bin/bashtest1=""for test in $(cat morningglory.2023-03-03.0.log |grep have | sed -r 's/.*have(.*)role.*/\1/'| sed s/[[:space:]]//g)do test1="$test"','"$test1"doneecho "$test1" >1.txt