Tool to help you manage your Grafana dashboards using Git.

1234567891011
  1. #!/bin/bash
  2. set -ex
  3. export DEBIAN_VERSION=$(date +"1.%Y.%m.%d.%H.%M.%S")
  4. export BASE=$(dirname $0)
  5. export GIT_BRANCH="$(git rev-parse --abbrev-ref HEAD)"
  6. [ -f ${BASE}/changelog ] && rm ${BASE}/changelog
  7. dch --newversion=${DEBIAN_VERSION} --create --noquery --distribution stable --package grafana-dashboard-manager "Build grafana-dashboard-manager from branch $GIT_BRANCH"
  8. debuild -e DEBIAN_VERSION -e GOROOT -e GOPATH -e PATH -us -uc -b $@