Skip to content

Instantly share code, notes, and snippets.

@bertptrs
Last active August 31, 2016 17:35
Show Gist options
  • Save bertptrs/5970c74998656ba9f805f00394d3bf26 to your computer and use it in GitHub Desktop.
Save bertptrs/5970c74998656ba9f805f00394d3bf26 to your computer and use it in GitHub Desktop.
A munin plugin for monitoring pacman updates
#!/bin/bash
case $1 in
config)
cat <<'EOM'
graph_args --base 1000 -l 0
graph_category pacman
graph_title Pending updates
graph_vlabel updates
updates.label updates
updates.info Current number of pending updates
updates.warning 1
EOM
exit 0;;
esac
echo updates.value $(checkupdates | wc -l)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment