Skip to content

Commit 8a55804

Browse files
feat: Use pipx to run id
* Requires id v1.4.0+
1 parent 0d7350d commit 8a55804

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

{{cookiecutter.project_name}}/{% if cookiecutter.__ci=='gitlab' %}.gitlab-ci.yml{% endif %}

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ before_script:
2121
- python -V
2222
- python -m venv .venv
2323
- source .venv/bin/activate
24-
- python -m pip install -U pip pipx id
24+
- python -m pip install -U pip pipx
2525
- python -m pipx ensurepath
2626
- python -m pip freeze
2727

@@ -153,7 +153,7 @@ make_wheels:
153153
{%- endif %}
154154
script:
155155
# Retrieve the OIDC token from GitLab CI/CD and exchange it for a PyPI API token
156-
- oidc_token=$(python -m id PYPI)
156+
- oidc_token=$(pipx run id PYPI)
157157
- response=$(curl -X POST "${OIDC_MINT_TOKEN_URL}" -d "{\"token\":\"${oidc_token}\"}")
158158
- api_token=$(jq --raw-output '.token' <<< "${response}")
159159

0 commit comments

Comments
 (0)