Fix the env var name to override default http client timeouts #35
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release SDK if needed | |
on: | |
pull_request: | |
branches: main | |
types: closed | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
if: github.event.pull_request.merged == true && contains(github.event.pull_request.head.ref, 'release/') | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Setup Python | |
uses: actions/setup-python@v1 | |
with: | |
python-version: 3.8 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install poetry | |
poetry install | |
- name: Build the package | |
run: poetry build | |
- name: Publish to PyPi | |
uses: pypa/gh-action-pypi-publish@release/v1 | |
with: | |
password: ${{ secrets.PYPI_API_TOKEN }} | |
- name: Create Release tag | |
id: create-tag | |
env: | |
PR_REF: ${{ github.event.pull_request.head.ref }} | |
run: | | |
release_tag=$(echo "$PR_REF" | cut -d "/" -f2) | |
echo "::set-output name=release-tag::$release_tag" | |
- name: Make new release | |
uses: ncipollo/release-action@v1 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
tag: ${{ steps.create-tag.outputs.release-tag }} | |
commit: main | |
body: ${{ github.event.pull_request.body }} |