This commit is contained in:
Jordan Bancino 2022-07-29 14:42:23 -04:00
parent 8e8ac04505
commit f1c0d6b40e

24
make.sh
View file

@ -131,6 +131,30 @@ recipe_release() {
fi
}
recipe_patch() {
if [ -z "$MXID" ]; then
MXID="@${USER}:$(hostname)"
fi
if [ -z "$DISPLAY_NAME" ]; then
DISPLAY_NAME=$(getent passwd "$USER" | cut -d ':' -f 5 | cut -d ',' -f 1)
fi
if [ -z "$EDITOR" ]; then
EDITOR=vi
fi
(
printf 'From: "%s" <%s>\n' "$DISPLAY_NAME" "$MXID"
echo "Date: $(date +%Y-%m-%d)"
echo "Subject: "
echo
cvs diff -uNp $PATCH | grep -v '^\? '
) > "telodendria-patch.patch"
"$EDITOR" "telodendria-patch.patch"
}
for recipe in $@; do
recipe_$recipe
done