#!/bin/sh

prefix="${0%/*}/notifications"	# $GIT_DIR/hooks/notifications
recipient='Monitoring Plugins Commits <commits@monitoring-plugins.org>'
maxcommits=100
maxdiffsize=$((300 * 1024))
project='monitoring-plugins'
gitweburl='https://github.com/monitoring-plugins/monitoring-plugins'
gitnotify="$prefix/git-notify.pl"
statefile="$prefix/git-notify.dat"

exec "$gitnotify" \
  -c "$project" \
  -m "$recipient" \
  -n "$maxcommits" \
  -s "$maxdiffsize" \
  -t "$statefile" \
  -u "$gitweburl" \
  -A \
  -C \
  -S \
  -T \
  -X \
  -z
