From 90753550be5edd82af46975086301bbadf95316a Mon Sep 17 00:00:00 2001 From: Daniel K Lyons <dlyons@nrao.edu> Date: Fri, 26 May 2023 15:56:29 -0600 Subject: [PATCH] Modify the pex-build template to match poetry --- ci/pex-build.template.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/pex-build.template.yml b/ci/pex-build.template.yml index 152fe729c..4ceeaea77 100644 --- a/ci/pex-build.template.yml +++ b/ci/pex-build.template.yml @@ -5,7 +5,7 @@ - pip install build twine - python -m build ${PEX_PATH} - pip install ${PEX_PATH} - - NAME=$(awk -F' = ' '/^\[project\]/ { project = 1; next } /^\[.*\]/ { project = 0 } project && $1 == "name" { gsub(/"/, "", $2); print $2 }' ${PEX_PATH}/pyproject.toml) + - NAME=$(awk -F' = ' '/^\[tool.poetry\]/ { project = 1; next } /^\[.*\]/ { project = 0 } project && $1 == "name" { gsub(/"/, "", $2); print $2 }' ${PEX_PATH}/pyproject.toml) - VERSION=$(sed -n 's/^__version__ = "\(.*\)\"$/\1/p' ${PEX_PATH}/*/__init__.py) - 'curl --header "JOB-TOKEN: $CI_JOB_TOKEN" --upload-file ${PEX_PATH}/dist/${NAME}-${VERSION}-py3-none-any.whl "$CI_API_V4_URL/projects/$CI_PROJECT_ID/packages/generic/${NAME}/${VERSION}/${NAME}-${VERSION}-py3-none-any.whl"' - pytest ${PEX_PATH}/test \ No newline at end of file -- GitLab