Skip to content

Commit

Permalink
uodated vorkflows and version
Browse files Browse the repository at this point in the history
  • Loading branch information
Grashalmbeisser committed Feb 21, 2024
1 parent b7405f8 commit edd1273
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 18 deletions.
54 changes: 39 additions & 15 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,30 +35,23 @@ jobs:
name: buildfiles
path: .

release:
name: ☀️ create release
publishtest:
if: "!startsWith(github.ref, 'refs/tags/v')"
name: 📦 publish to TestPyPI
runs-on: ubuntu-latest
needs: [build]
if: "startsWith(github.ref, 'refs/tags/v')"
needs: [ build ]

steps:
- uses: actions/download-artifact@master
with:
name: buildfiles
path: .

- name: Get version from tag
id: tag_name
run: |
echo ::set-output name=current_version::${GITHUB_REF#refs/tags/v}
- name: create release
uses: softprops/action-gh-release@v1
- name: Publish distribution 📦 to Test PyPI
uses: pypa/gh-action-pypi-publish@master
with:
files: dist/*
body: ${{ steps.changelog_reader.outputs.changes }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository_url: https://test.pypi.org/legacy/

publish:
if: "startsWith(github.ref, 'refs/tags/v')"
Expand Down Expand Up @@ -87,3 +80,34 @@ jobs:
uses: pypa/gh-action-pypi-publish@master
with:
password: ${{ secrets.PYPI_API_TOKEN }}

release:
name: ☀️ create release
runs-on: ubuntu-latest
needs: [build]
if: "startsWith(github.ref, 'refs/tags/v')"

steps:
- uses: actions/download-artifact@master
with:
name: buildfiles
path: .

- name: Get version from tag
id: tag_name
run: |
echo ::set-output name=current_version::${GITHUB_REF#refs/tags/v}
- name: fetch changelog info
id: changelog_reader
uses: mindsers/changelog-reader-action@v2
with:
version: ${{ steps.tag_name.outputs.current_version }}

- name: create release
uses: softprops/action-gh-release@v1
with:
files: dist/*
body: ${{ steps.changelog_reader.outputs.changes }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
This file documents any relevant changes.

## [2.0.0-dev4] 2024-02-19
- chore: updated github workflows
- chore: updated Github workflows

## [2.0.0-dev3] 2024-02-19
- feature: appengine Setup can now be done via CLI
- feature: Appengine Setup can now be done via CLI
- feature: Appengine Roles can now be managed via CLI
- feature: `viur package install` and `viur package update` functions

Expand Down
2 changes: 1 addition & 1 deletion src/viur_cli/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
__version__ = "2.0.0.dev4"
__version__ = "2.0.0-dev4"
MINIMAL_PIPENV = "2023.11.15"

0 comments on commit edd1273

Please sign in to comment.