
Some checks failed
CI - 4NK Node / Integration Tests (push) Failing after 9s
CI - 4NK Node / Docker Build & Test (push) Failing after 8s
CI - 4NK Node / Documentation Tests (push) Failing after 3s
CI - 4NK Node / Release Guard (push) Has been skipped
CI - 4NK Node / Performance Tests (push) Failing after 29s
CI - 4NK Node / Code Quality (push) Failing after 32s
CI - 4NK Node / Unit Tests (push) Failing after 30s
CI - 4NK Node / Security Tests (push) Failing after 28s
CI - 4NK Node / Notify (push) Failing after 1s
21 lines
580 B
Bash
21 lines
580 B
Bash
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")"/../.. && pwd)"
|
|
cd "$ROOT_DIR"
|
|
|
|
version_file="VERSION"
|
|
[[ -f TEMPLATE_VERSION ]] && version_file="TEMPLATE_VERSION"
|
|
|
|
[[ -f "$version_file" ]] || { echo "Version file missing ($version_file)"; exit 1; }
|
|
v=$(tr -d '\r' < "$version_file" | head -n1)
|
|
[[ -n "$v" ]] || { echo "Empty version"; exit 1; }
|
|
|
|
echo "Version file: $version_file=$v"
|
|
|
|
if ! grep -Eq "^## \\[$(echo "$v" | sed 's/^v//')\\]" CHANGELOG.md; then
|
|
echo "CHANGELOG entry for $v not found"; exit 1;
|
|
fi
|
|
|
|
echo "Version alignment OK"
|