Skip to content

Merge pull request #14 from Parzival1918/force_fields_plotting #24

Merge pull request #14 from Parzival1918/force_fields_plotting

Merge pull request #14 from Parzival1918/force_fields_plotting #24

Workflow file for this run

name: Publish to PYPI
on:
push:
branches: [ main ]
jobs:
build:
strategy:
fail-fast: false
matrix:
python-version: [3.11]
poetry-version: [1.5.1]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install poetry ${{ matrix.poetry-version }}
run: |
python -m ensurepip
python -m pip install --upgrade pip
python -m pip install poetry==${{ matrix.poetry-version }}
- name: View poetry --help
run: poetry --help
- name: Install dependencies
shell: bash
run: python -m poetry install
- name: Test with pytest
run: |
python -m poetry run python -m pytest -v tests
publish:
# needs: build
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.11]
poetry-version: [1.5.1]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install poetry ${{ matrix.poetry-version }}
run: |
python -m ensurepip
python -m pip install --upgrade pip
python -m pip install poetry==${{ matrix.poetry-version }}
- name: Install dependencies
shell: bash
run: python -m poetry install
- name: Publish to test PyPi package
env:
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
# run: |
# python -m poetry config repositories.test-pypi https://test.pypi.org/legacy/
# python -m poetry config pypi-token.test-pypi $PYPI_TOKEN
# python -m poetry publish --build -r test-pypi
run: |
python -m poetry config pypi-token.pypi $PYPI_TOKEN
python -m poetry publish --build
# - name: Publish to PyPi package
# env:
# PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
# run: |
# python -m poetry config http-basic.pypi __token__ $PYPI_TOKEN
# python -m poetry publish --build