Commits

Anonymous committed 2b22957

use $MARGIN in sed

Comments (0)

Files changed (1)

extras/cw_color.sh

 done
 
 cw "$IN" "$OUT" "$MARGIN" |
-	sed -e "s/^\([-0-9]\{10,10\}\) \([:0-9]\{5,5\}\) <\([^>]*\)>/${yellow}\1 ${green}\2${reset} <${cyan}\3${reset}>/" \
+	sed -e "s/^\([-0-9]\{10,10\}\) \([:0-9]\{5,5\}\) <\([^$MARGIN]*\)>/${yellow}\1 ${green}\2${reset} <${cyan}\3${reset}>/" \
 		-e "s/^\([-0-9]\{10,10\}\) \([:0-9]\{5,5\}\) \(-!-\)/${yellow}\1 ${green}\2${reset} ${magenta}\3${reset}/" \
 		-e "s/^\([-0-9]\{10,10\}\) \([:0-9]\{5,5\}\)/${yellow}\1 ${green}\2${reset}/" \
 		-e "s/$NICK/\a${red}&${reset}/g"