Skip to content

Commit

Permalink
fix: run publish on ubuntu
Browse files Browse the repository at this point in the history
  • Loading branch information
RyanWhite25 committed Oct 17, 2024
1 parent 7bf6736 commit 699d235
Showing 1 changed file with 24 additions and 2 deletions.
26 changes: 24 additions & 2 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ on:
push:

jobs:
test:
test-code:
runs-on: "macos-latest"
steps:
- name: Checkout code
Expand All @@ -27,14 +27,36 @@ jobs:
run: |
bash scripts/test.sh --ci
test-publish:
if: github.ref_name == github.event.repository.default_branch
runs-on: ubuntu-latest
needs:
- test-code
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Install poetry
run: pipx install poetry

- name: Setup Python 3.12
uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: "poetry"

- name: Install dependencies
run: |
poetry env use "3.12"
poetry install
- name: Bump version number
run: poetry version 0.0.0

- name: Build package
run: poetry build

- name: Publish to test pypi
if: github.ref_name == github.event.repository.default_branch
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository-url: 'https://test.pypi.org/legacy/'

0 comments on commit 699d235

Please sign in to comment.