Skip to content

Commit c47babf

Browse files
authored
Merge pull request #9 from extinctCoder/sas-branch-4
chore(release): add semantic-release config and release workflow
2 parents 6724cb3 + 8d4eef2 commit c47babf

2 files changed

Lines changed: 41 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Automated version release Schedule
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches:
7+
- main
8+
9+
# on:
10+
# pull_request:
11+
# types:
12+
# - closed
13+
14+
jobs:
15+
ScheduledRelease:
16+
# if: github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'main' && github.event.pull_request.merged == true
17+
18+
runs-on: ubuntu-latest
19+
concurrency: release
20+
permissions:
21+
id-token: write
22+
contents: write
23+
24+
steps:
25+
- name: Checkout code repository
26+
id: code_checkout
27+
uses: actions/checkout@v4
28+
with:
29+
fetch-depth: 0
30+
31+
- name: Releasing new version with Python semantic release
32+
id: release_version
33+
uses: python-semantic-release/python-semantic-release@master
34+
with:
35+
github_token: ${{ secrets.GITHUB_TOKEN }}

pyproject.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[tool.poetry]
2+
version = "0.10.1"
3+
name = "smart_grid"
4+
5+
[tool.semantic_release]
6+
version_toml = ["pyproject.toml:tool.poetry.version:nf"]

0 commit comments

Comments
 (0)