git_root=$(git -C ${repo} rev-parse --show-toplevel)
if [ -f ${git_root}/update ]; then
shortlog=$(git -C ${git_root} log --pretty=oneline --follow -- update)
-
while IFS= read -r line; do
- hash=$(echo ${line} | cut -d ' ' -f 1)
+ hash=$(printf ${line} | cut -d " " -f 1)
git -C ${git_root} show ${hash}:update | tail -n +2 > /tmp/kiss-mail
- printf '+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++\n'
- printf %s $((i = i + 1))
+ printf "+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++\n"
+ printf "Item: %s" $((i = i + 1))
printf "\n"
- git -C ${git_root} show -s ${hash}
- printf '+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++\n'
+ git -C ${git_root} show -s ${hash} | tail -n +2
+ printf "+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++\n"
/tmp/kiss-mail
printf "\n\n"
done
}
-[ -z ${PAGER} ] || pager_l=${PAGER} && pager_l="less"
+[ -z ${PAGER} ] || pager_l=${PAGER} && pager_l="less -R"
get_mail | ${pager_l}