Merge pull request #297 from juaml/bug/fix_optuna_cv #10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and publish | |
| on: | |
| push: | |
| branches: | |
| - main | |
| tags: | |
| - 'v*' | |
| jobs: | |
| build-and-publish: | |
| name: Build and publish | |
| runs-on: ubuntu-latest | |
| permissions: | |
| # Needed for PyPI publishing | |
| id-token: write | |
| # Needed for GitHub releases | |
| contents: write | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| fetch-depth: 0 | |
| submodules: true | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.x" | |
| - name: Install build | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install build | |
| - name: Build package | |
| run: | |
| python -m build | |
| - uses: pypa/gh-action-pypi-publish@release/v1 | |
| - uses: softprops/action-gh-release@v2 | |
| with: | |
| files: | | |
| dist/*.tar.gz | |
| dist/*.whl | |
| generate_release_notes: true | |
| make_latest: true | |
| if: startsWith(github.ref, 'refs/tags/') |