Skip to content

Bump version to 1.2.1 #5

Bump version to 1.2.1

Bump version to 1.2.1 #5

Workflow file for this run

name: release
on:
push:
tags:
- "v*"
permissions:
contents: write
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
- name: Build dataset
run: node scripts/build.js
- name: Extract version from tag
id: version
run: echo "version=${GITHUB_REF#refs/tags/v}" >> "$GITHUB_OUTPUT"
- name: Extract changelog for this version
id: changelog
run: |
# Extract the section for this version from CHANGELOG.md
awk '/^## \['"${{ steps.version.outputs.version }}"'\]/{found=1; next} /^## /{if(found) exit} found' CHANGELOG.md > /tmp/release-notes.md
echo "body<<RELEASE_EOF" >> "$GITHUB_OUTPUT"
cat /tmp/release-notes.md >> "$GITHUB_OUTPUT"
echo "RELEASE_EOF" >> "$GITHUB_OUTPUT"
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
name: v${{ steps.version.outputs.version }}
body: ${{ steps.changelog.outputs.body }}
files: |
data/cameras.json
data/cameras.csv