#!/usr/bin/env bash # # This is the nightly changelog generation script # It is responsible for two major activities: # 1) Update packaging/version with the current nightly version # 2) Generate the changelog for the mentioned version # # Copyright: SPDX-License-Identifier: GPL-3.0-or-later # # Author : Pawel Krupa (paulfantom) # Author : Pavlos Emm. Katsoulakis (paul@netdata.cloud) set -e FAIL=0 source tests/installer/slack.sh || echo "Could not load slack library" # If we are not in netdata git repo, at the top level directory, fail TOP_LEVEL=$(basename "$(git rev-parse --show-toplevel)") CWD=$(git rev-parse --show-cdup || echo "") if [ -n "${CWD}" ] || [ ! "${TOP_LEVEL}" == "netdata" ]; then echo "Run as .travis/$(basename "$0") from top level directory of netdata git repository" echo "Changelog generation process aborted" exit 1 fi LAST_TAG=$(git describe --abbrev=0 --tags) COMMITS_SINCE_RELEASE=$(git rev-list "${LAST_TAG}"..HEAD --count) PREVIOUS_NIGHTLY_COUNT="$(rev