Skip to content

Commit 4edf2ea

Browse files
✨ feat: add package version to github workflow #20
1 parent 62ab8df commit 4edf2ea

4 files changed

Lines changed: 10 additions & 2 deletions

File tree

.github/workflows/dev.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,8 @@ jobs:
6060
run: |
6161
python -m pip install --upgrade pip
6262
pip install poetry tox tox-gh-actions
63+
echo "package_version_short=`poetry version --short`.DEV.$GITHUB_RUN_NUMBER" > $GITHUB_ENV
64+
echo "package_version_full"=`poetry version`.DEV.$GITHUB_RUN_NUMBER >> $GITHUB_ENV
6365
6466
- name: build documentation
6567
run: |
@@ -75,7 +77,7 @@ jobs:
7577
with:
7678
personal_token: ${{ secrets.PERSONAL_TOKEN }}
7779
publish_dir: ./site
78-
80+
7981
- name: Build wheels and source tarball
8082
run: |
8183
poetry version $(poetry version --short)-dev.$GITHUB_RUN_NUMBER

.github/workflows/release.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ jobs:
4343
run: |
4444
python -m pip install --upgrade pip
4545
pip install tox-gh-actions poetry
46+
echo "package_version_short=`poetry version --short`" > $GITHUB_ENV
47+
echo "package_version_full"=`poetry version` >> $GITHUB_ENV
4648
4749
- name: pre-publish documentation
4850
run: |

{{cookiecutter.project_slug}}/.github/workflows/dev.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ jobs:
7272
run: |
7373
python -m pip install --upgrade pip
7474
pip install poetry tox tox-gh-actions
75+
echo "package_version_short=`poetry version --short`.DEV.$GITHUB_RUN_NUMBER" > $GITHUB_ENV
76+
echo "package_version_full"=`poetry version`.DEV.$GITHUB_RUN_NUMBER >> $GITHUB_ENV
7577
7678
- name: build documentation
7779
run: |
@@ -87,7 +89,7 @@ jobs:
8789
with:
8890
personal_token: ${{ secrets.PERSONAL_TOKEN }}
8991
publish_dir: ./site
90-
92+
9193
- name: Build wheels and source tarball
9294
run: |
9395
poetry version $(poetry version --short)-dev.$GITHUB_RUN_NUMBER

{{cookiecutter.project_slug}}/.github/workflows/release.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ jobs:
4343
run: |
4444
python -m pip install --upgrade pip
4545
pip install tox-gh-actions poetry
46+
echo "package_version_short=`poetry version --short`" > $GITHUB_ENV
47+
echo "package_version_full"=`poetry version` >> $GITHUB_ENV
4648
4749
- name: pre-publish documentation
4850
run: |

0 commit comments

Comments
 (0)