contact=$(get_contacts "$branch")
subject=${1//BRANCH/$branch}
-filter="sed -e 's/BRANCH/$branch/g'"
-if [ "$kconfig" ]; then
- filter="$filter -e 's/KCONFIG_NAME/$kconfig/g'"
+filter=( -e "s/BRANCH/$branch/g" )
+if [ -n "$kconfig" ]; then
+ filter+=( -e "s/KCONFIG_NAME/$kconfig/g" )
fi
-filter="$filter | fmt -s"
-{ printf 'Hi all,\n\n'; eval "$filter"; } |
- "$bin_dir"/send_email "linux-next: $subject" "$contact" "${cc[@]}"
+{
+ printf 'Hi all,\n\n'
+ sed "${filter[@]}" | fmt -s
+} | "$bin_dir"/send_email "linux-next: $subject" "$contact" "${cc[@]}"
exit 0