Skip to content

Commit

Permalink
Generate release notes
Browse files Browse the repository at this point in the history
  • Loading branch information
mr-eyes committed Oct 27, 2024
1 parent 88370a4 commit d2b38f0
Showing 1 changed file with 8 additions and 10 deletions.
18 changes: 8 additions & 10 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -99,13 +99,14 @@ jobs:
- name: Extract Version from __init__.py
id: extract_version
run: |
VERSION=$(python -c "import re;
import pathlib;
init_file = pathlib.Path('src/snipe/__init__.py');
content = init_file.read_text();
match = re.search(r'__version__\s*=\s*[\'\"]([^\'\"]+)[\'\"]', content);
VERSION=$(python -c "import re; \
import pathlib; \
init_file = pathlib.Path('src/snipe/__init__.py'); \
content = init_file.read_text(); \
match = re.search(r'__version__\s*=\s*[\'\"]([^\'\"]+)[\'\"]', content); \
print(match.group(1) if match else '0.0.0')")
echo "VERSION=$VERSION" >> $GITHUB_ENV
- name: Build package
run: |
hatch build
Expand All @@ -130,8 +131,5 @@ jobs:
with:
tag: "v${{ env.VERSION }}"
name: "v${{ env.VERSION }}"
body: |
Release version ${{ env.VERSION }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

generateReleaseNotes: true
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit d2b38f0

Please sign in to comment.