Skip to content

Commit 666efa3

Browse files
authored
Merge pull request #377 from naik-aakash/ci_updates
Ci updates
2 parents 9e8c7c2 + d06fd8f commit 666efa3

File tree

4 files changed

+66
-6
lines changed

4 files changed

+66
-6
lines changed

.github/release.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
changelog:
2+
exclude:
3+
authors: [ dependabot, github-actions ]
4+
labels: [automated-pr]
5+
categories:
6+
- title: 🚀 New Features
7+
labels:
8+
- enhancement
9+
- title: 🐛 Bug Fixes
10+
labels:
11+
- bug
12+
- title: Enhancements 🛠
13+
labels:
14+
- enhancement
15+
- title: 📚 Documentation
16+
labels:
17+
- documentation
18+
- title: 🧹 House-Keeping
19+
labels:
20+
- housekeeping
21+
- title: 🔄 Other Changes
22+
labels:
23+
- "*"

.github/workflows/python-package.yml

+2
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,8 @@ jobs:
161161
title: Update test durations file
162162
body: Auto updated test durations file
163163
branch: update-test-durations
164+
labels: |
165+
automated-pr
164166
delete-branch: true
165167
base: main
166168

.github/workflows/python-publish.yml

+38-2
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,47 @@ on:
1313
types: [published]
1414

1515
jobs:
16-
deploy:
17-
16+
update-changelog:
1817
runs-on: ubuntu-latest
18+
steps:
19+
- name: Checkout Repository
20+
uses: actions/checkout@v4
21+
22+
- name: Fetch Version Tag & Release Notes
23+
id: get_release_info
24+
run: |
25+
echo "VERSION=${{ github.event.release.tag_name }}" >> $GITHUB_ENV
26+
echo "NOTES<<EOF" >> $GITHUB_ENV
27+
gh release view ${{ github.event.release.tag_name }} --json body -q .body >> $GITHUB_ENV
28+
echo "EOF" >> $GITHUB_ENV
29+
env:
30+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
31+
32+
- name: Insert Version Tag & Release Notes Below `# Changelog`
33+
run: |
34+
{ echo "# Changelog"; echo; echo "## $VERSION"; echo; echo "$NOTES"; echo; tail -n +2 CHANGELOG.md; } > temp.md && mv temp.md CHANGELOG.md
1935
36+
- name: Create Pull Request to push updated CHANGELOG.md
37+
uses: peter-evans/create-pull-request@v7
38+
with:
39+
commit-message: update CHANGELOG
40+
title: Update changelog with latest release notes
41+
body: Update CHANGELOG.md to reflect release changes
42+
branch: update-changelog
43+
labels: |
44+
automated-pr
45+
delete-branch: true
46+
base: main
47+
48+
deploy:
49+
needs: update-changelog
50+
runs-on: ubuntu-latest
2051
steps:
52+
- name: Pause for 5 minutes to merge update Changelog PR
53+
run: |
54+
echo "Wait for 5 minutes to merge PR..."
55+
sleep 300
56+
echo "Resuming workflow..."
2157
- uses: actions/checkout@v4
2258
- name: Set up Python
2359
uses: actions/setup-python@v4

pyproject.toml

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
[build-system]
22
requires = [
33
"setuptools>=65.0.0",
4+
"setuptools-scm>=8.0",
45
"wheel",
56
]
67
build-backend = "setuptools.build_meta"
@@ -17,7 +18,7 @@ readme = "README.md"
1718
keywords = ["high-throughput", "automated", "lobsteroutput", "bonding-analysis"]
1819
license = { text = "BSD 3-Clause" }
1920
authors = [{ name = "Janine George", email = "janine.george@bam.de" }]
20-
version = "0.5.4"
21+
dynamic = ["version"]
2122
classifiers = [
2223
"Programming Language :: Python :: 3",
2324
"Programming Language :: Python :: 3.10",
@@ -59,9 +60,7 @@ docs = [
5960
[project.scripts]
6061
lobsterpy = "lobsterpy.cli:main"
6162

62-
[tool.versioningit.vcs]
63-
method = "git"
64-
default-tag = "0.0.1"
63+
[tool.setuptools_scm]
6564

6665

6766
[tool.cibuildwheel.linux]

0 commit comments

Comments
 (0)