Skip to content

Commit

Permalink
yaml indent
Browse files Browse the repository at this point in the history
  • Loading branch information
atz committed Jun 13, 2023
1 parent 5b9f856 commit 9fb31cb
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ jobs:
steps:
- name: Tag Check
run: |
sed -En '/\[tool.poetry\]/,/^version/{ s/^version *= *"(.+)"/\1/p; }' pyproject.toml | read toml_version
cat <<-EOF
GITHUB_REF_TYPE: $GITHUB_REF_TYPE
GITHUB_REF_NAME: $GITHUB_REF_NAME
pyproject.toml[tool.poetry.version]: $toml_version
EOF
bail() { echo "Error: pyproject.toml 'version' and git release tag must match" ; exit 1 }
[[ "${GITHUB_REF_TYPE}" == 'tag' ]] || bail
[[ "${GITHUB_REF_NAME}" == "${toml_version}" ]] || bail
sed -En '/\[tool.poetry\]/,/^version/{ s/^version *= *"(.+)"/\1/p; }' pyproject.toml | read toml_version
cat <<-EOF
GITHUB_REF_TYPE: $GITHUB_REF_TYPE
GITHUB_REF_NAME: $GITHUB_REF_NAME
pyproject.toml[tool.poetry.version]: $toml_version
EOF
bail() { echo "Error: pyproject.toml 'version' and git release tag must match" ; exit 1 }
[[ "${GITHUB_REF_TYPE}" == 'tag' ]] || bail
[[ "${GITHUB_REF_NAME}" == "${toml_version}" ]] || bail
- name: Checkout
uses: actions/checkout@v3
with:
Expand Down

0 comments on commit 9fb31cb

Please sign in to comment.