Skip to content

fix(swift-sections): guard SymbolIndexStore race + align section readers with ABI #7

fix(swift-sections): guard SymbolIndexStore race + align section readers with ABI

fix(swift-sections): guard SymbolIndexStore race + align section readers with ABI #7

Workflow file for this run

name: Version Check
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
version-check:
name: Verify version metadata
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Extract BundledVersion.value
id: version
run: |
set -euo pipefail
file="Sources/swift-section/Version.swift"
value=$(grep -m1 -E 'static[[:space:]]+let[[:space:]]+value[[:space:]]*=[[:space:]]*"[^"]+"' "$file" | sed -E 's/.*"([^"]+)".*/\1/' || true)
if [ -z "$value" ]; then
echo "::error file=$file::Failed to extract BundledVersion.value"
exit 1
fi
echo "version=$value" >> "$GITHUB_OUTPUT"
echo "BundledVersion.value = $value"
- name: Verify matching changelog exists
run: |
set -euo pipefail
value="${{ steps.version.outputs.version }}"
changelog="Changelogs/$value.md"
if [ ! -f "$changelog" ]; then
echo "::error file=Sources/swift-section/Version.swift::Missing $changelog — every BundledVersion.value must have a matching changelog. Either create $changelog or adjust Version.swift."
exit 1
fi
echo "Found $changelog"