Skip to content

Commit 8077b39

Browse files
MatrixAclaude
andauthored
Release 0.2.0: bump version, update changelog, add release workflow (#18)
Bump version to 0.2.0 with new features (10 AI tools, video frame watermark analysis, MP4 SEI markers). Add GitHub Actions workflow that auto-publishes to crates.io on minor/major version bumps. Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 604cc97 commit 8077b39

4 files changed

Lines changed: 83 additions & 2 deletions

File tree

.github/workflows/release.yml

Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
permissions:
8+
contents: write
9+
10+
jobs:
11+
release:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
17+
18+
- name: Read version from Cargo.toml
19+
id: version
20+
run: |
21+
VERSION=$(grep -m1 '^version' Cargo.toml | sed 's/.*"\(.*\)".*/\1/')
22+
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
23+
echo "Detected version: $VERSION"
24+
25+
- name: Check if release is needed
26+
id: check
27+
run: |
28+
VERSION="${{ steps.version.outputs.version }}"
29+
PATCH=$(echo "$VERSION" | cut -d. -f3)
30+
TAG="v$VERSION"
31+
32+
if [ "$PATCH" != "0" ]; then
33+
echo "Patch version is $PATCH (not 0) -- skipping release."
34+
echo "should_release=false" >> "$GITHUB_OUTPUT"
35+
exit 0
36+
fi
37+
38+
if git rev-parse "$TAG" >/dev/null 2>&1; then
39+
echo "Tag $TAG already exists -- skipping release."
40+
echo "should_release=false" >> "$GITHUB_OUTPUT"
41+
exit 0
42+
fi
43+
44+
echo "Will release $TAG"
45+
echo "should_release=true" >> "$GITHUB_OUTPUT"
46+
echo "tag=$TAG" >> "$GITHUB_OUTPUT"
47+
48+
- name: Extract changelog for this version
49+
if: steps.check.outputs.should_release == 'true'
50+
id: changelog
51+
run: |
52+
VERSION="${{ steps.version.outputs.version }}"
53+
awk "/^## \\[$VERSION\\]/{found=1; next} /^## \\[/{if(found) exit} found{print}" CHANGELOG.md > /tmp/release-notes.md
54+
echo "Extracted changelog:"
55+
cat /tmp/release-notes.md
56+
57+
- name: Create git tag
58+
if: steps.check.outputs.should_release == 'true'
59+
run: |
60+
git tag "${{ steps.check.outputs.tag }}"
61+
git push origin "${{ steps.check.outputs.tag }}"
62+
63+
- name: Create GitHub Release
64+
if: steps.check.outputs.should_release == 'true'
65+
env:
66+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
67+
run: |
68+
gh release create "${{ steps.check.outputs.tag }}" \
69+
--title "${{ steps.check.outputs.tag }}" \
70+
--notes-file /tmp/release-notes.md
71+
72+
- uses: dtolnay/rust-toolchain@stable
73+
if: steps.check.outputs.should_release == 'true'
74+
75+
- name: Publish to crates.io
76+
if: steps.check.outputs.should_release == 'true'
77+
env:
78+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
79+
run: cargo publish

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [0.2.0] - 2026-03-13
11+
1012
### Added
1113

1214
- 10 new AI tool recognitions: Grok, Gemini, Jimeng (即梦), Luma, Hailuo (海螺), Pixverse, Genmo, Haiper, Hume, Fish Audio (51 → 61 tools)

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "aicheck"
3-
version = "0.1.0"
3+
version = "0.2.0"
44
edition = "2021"
55
rust-version = "1.86"
66
description = "Detect AI-generated content via provenance signals (C2PA, XMP/IPTC, EXIF)"

0 commit comments

Comments
 (0)