Skip to content

Commit

Permalink
Fix actions
Browse files Browse the repository at this point in the history
  • Loading branch information
FelixS90 committed Jun 6, 2024
1 parent e8f9052 commit b610ceb
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 24 deletions.
7 changes: 3 additions & 4 deletions .github/actions/steps_package/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,10 @@ inputs:
runs:
using: composite
steps:
- name: Use Python ${{inputs.PyVersionLatest}}
uses: actions/setup-python@v5.0.0
- uses: "./.github/actions/steps_psr"
with:
python-version: "${{inputs.PyVersionLatest}}"
architecture: x64
PyVersionLatest: "${{inputs.PyVersionLatest}}"
PkgRootFolder: "${{inputs.PkgRootFolder}}"
- name: Install dependencies
run: |-
set -o errexit
Expand Down
22 changes: 22 additions & 0 deletions .github/actions/steps_psr/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Package
inputs:
PyVersionLatest:
required: true
PkgRootFolder:
required: true
runs:
using: composite
steps:
- name: Use Python ${{inputs.PyVersionLatest}}
uses: actions/setup-python@v5.0.0
with:
python-version: "${{inputs.PyVersionLatest}}"
architecture: x64
- name: Python Semantic Release Setup
run: python -m pip install --upgrade python-semantic-release
working-directory: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
- name: Python Semantic Release
id: pythonsemanticrelease
working-directory: "${{inputs.PkgRootFolder}}"
# TODO: Patch only for testing
run: semantic-release -vv -c python-semantic-release.json version --patch --changelog --no-commit --no-tag --no-push --no-vcs-release --skip-build
36 changes: 16 additions & 20 deletions .github/workflows/build-reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,10 @@ jobs:
submodules: recursive
# Python Semantic Release needs access to the full history to determine whether a release should be made.
fetch-depth: 0
- name: Use Python ${{inputs.PyVersionLatest}}
uses: actions/setup-python@v5.0.0
- uses: "./.github/actions/steps_psr"
with:
python-version: "${{inputs.PyVersionLatest}}"
architecture: x64
- name: Python Semantic Release Setup
run: python -m pip install --upgrade python-semantic-release
working-directory: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
- name: Python Semantic Release
id: pythonsemanticrelease
working-directory: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
# TODO: Patch only for testing
run: semantic-release -vv -c python-semantic-release.json version --patch --changelog --no-commit --no-tag --no-push --no-vcs-release --skip-build
PyVersionLatest: "${{inputs.PyVersionLatest}}"
PkgRootFolder: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
- name: Environment Setup
run: python -m pip install --upgrade --requirement requirements_test.txt
working-directory: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
Expand Down Expand Up @@ -141,6 +132,8 @@ jobs:
with:
lfs: true
submodules: recursive
# Python Semantic Release needs access to the full history to determine whether a release should be made.
fetch-depth: 0
- uses: "./.github/actions/steps_package"
with:
PyVersionLatest: "${{inputs.PyVersionLatest}}"
Expand All @@ -157,11 +150,12 @@ jobs:
with:
lfs: true
submodules: recursive
- name: Use Python ${{inputs.PyVersionLatest}}
uses: actions/setup-python@v5.0.0
# Python Semantic Release needs access to the full history to determine whether a release should be made.
fetch-depth: 0
- uses: "./.github/actions/steps_psr"
with:
python-version: "${{inputs.PyVersionLatest}}"
architecture: x64
PyVersionLatest: "${{inputs.PyVersionLatest}}"
PkgRootFolder: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
- name: Environment Setup
run: python -m pip install --upgrade --requirement requirements_deploy.txt
working-directory: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
Expand All @@ -181,11 +175,12 @@ jobs:
with:
lfs: true
submodules: recursive
- name: Use Python ${{inputs.PyVersionLatest}}
uses: actions/setup-python@v5.0.0
# Python Semantic Release needs access to the full history to determine whether a release should be made.
fetch-depth: 0
- uses: "./.github/actions/steps_psr"
with:
python-version: "${{inputs.PyVersionLatest}}"
architecture: x64
PyVersionLatest: "${{inputs.PyVersionLatest}}"
PkgRootFolder: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
- name: Environment Setup
run: python -m pip install --upgrade --requirement requirements_deploy.txt
working-directory: "${{ github.workspace }}/${{inputs.PkgRootFolder}}"
Expand Down Expand Up @@ -292,6 +287,7 @@ jobs:
permissions:
contents: write
needs: Upload
if: needs.Upload.result == 'success'
runs-on: windows-2019
steps:
- uses: actions/checkout@v4.1.0
Expand Down

0 comments on commit b610ceb

Please sign in to comment.