Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Changelog

## KitePodModels v0.4.1 - 2026-08-12
### Changed
- Bump `KiteUtils` to 0.12.
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "KitePodModels"
uuid = "9de5dc81-f971-414a-927b-652b2f41c539"
authors = ["Uwe Fechner <uwe.fechner.msc@gmail.com> and contributors"]
version = "0.4.0"
version = "0.4.1"

[deps]
DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
Expand All @@ -12,7 +12,7 @@ Reexport = "189a3867-3050-52da-a836-e630ba90ab69"
ControlPlots = "0.2"
LaTeXStrings = "1.3"
DocStringExtensions = "0.8, 0.9"
KiteUtils = "0.11"
KiteUtils = "0.12"
Reexport = "1.2"
julia = "1.10, 1.11, 1.12"

Expand Down
88 changes: 88 additions & 0 deletions bin/release
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
#!/bin/bash -eu
# SPDX-FileCopyrightText: 2026 Uwe Fechner
# SPDX-License-Identifier: MIT

# Create a new release by posting to JuliaRegistrator via issue #1
#
# Usage: bin/release
#
# This script extracts the latest release notes from CHANGELOG.md
# and posts them as a comment to GitHub issue #1 using the GitHub CLI.

set -euo pipefail

cd "$(dirname "$0")/.."

CHANGELOG="CHANGELOG.md"

if [ ! -f "$CHANGELOG" ]; then
echo "Error: $CHANGELOG not found" >&2
exit 1
fi

# Check that we are on the main branch
branch=$(git rev-parse --abbrev-ref HEAD)
if [ "$branch" != "main" ]; then
echo "Error: Must be on the 'main' branch (currently on '$branch')" >&2
exit 1
fi

# Check that the working tree is clean (no staged, unstaged, or untracked changes)
if [ -n "$(git status --porcelain)" ]; then
echo "Error: There are uncommitted or untracked changes. Please commit or stash them first." >&2
exit 1
fi

# Extract the first release section: from "## KitePodModels v..." up to
# (but not including) the next "## KitePodModels" or end of file.
release_notes=$(awk '
/^## KitePodModels / {
if (version == "") {
version = $2
next
}
exit
}
version != "" { print }
' "$CHANGELOG")

if [ -z "$release_notes" ]; then
echo "Error: Could not find release notes in $CHANGELOG" >&2
exit 1
fi

# Get version string (e.g. "v0.4.1")
version=$(awk '/^## KitePodModels v/ {print $3; exit}' "$CHANGELOG")

# Check that the version in Project.toml matches the version in CHANGELOG.md
project_version=$(awk -F'"' '/^version = / {print $2; exit}' Project.toml)
changelog_version="${version#v}"
if [ "$project_version" != "$changelog_version" ]; then
echo "Error: Version mismatch: Project.toml has '$project_version', CHANGELOG.md has '$changelog_version'" >&2
exit 1
fi

echo "About to trigger registration for: KitePodModels $version"
echo ""
echo "Release notes:"
echo "$release_notes"
echo ""
read -r -p "Continue? [y/N] " response
if [ "$response" != "y" ] && [ "$response" != "Y" ]; then
echo "Aborted."
exit 0
fi

# Build the comment body and pipe it to gh
{
echo '@JuliaRegistrator register'
echo ""
echo "Release notes:"
echo ""
echo "$release_notes"
} | gh issue comment 1 \
--repo "aenarete/KitePodModels.jl" \
--body-file -

echo ""
echo "Done! Registration comment posted to https://github.com/aenarete/KitePodModels.jl/issues/1"
Loading