Skip to content

Commit

Permalink
fix publish command
Browse files Browse the repository at this point in the history
  • Loading branch information
RobinKa committed Sep 28, 2023
1 parent 8df5537 commit 0031b6e
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ base-python:
FROM python:3.8

# Install Poetry
ENV PIP_CACHE_DIR /var/cache/buildkit/pip
ENV PIP_CACHE_DIR /pip-cache
RUN --mount=type=cache,target=$PIP_CACHE_DIR \
pip install poetry==1.6.1
RUN --mount=type=cache,target=$PIP_CACHE_DIR \
Expand Down Expand Up @@ -53,8 +53,13 @@ test-examples:
END

publish:
FROM +build

RUN poetry config repositories.pypi https://upload.pypi.org/legacy/
RUN poetry config repositories.testpypi https://test.pypi.org/legacy/

RUN --mount=type=cache,target=$PIP_CACHE_DIR \
--secret PYPI_TOKEN=+secrets/PYPI_TOKEN \
poetry publish \
--build --skip-existing -r $REPOSITORY \
-u __token__ -p $PYPI_TOKEN
--secret PYPI_TOKEN=+secrets/PYPI_TOKEN \
poetry publish \
--build --skip-existing -r $REPOSITORY \
-u __token__ -p $PYPI_TOKEN

0 comments on commit 0031b6e

Please sign in to comment.