Give the ability to set extra
when initializing a logger
#9
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 | |
on: | |
push: | |
tags: | |
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 | |
jobs: | |
release: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-python@v2 | |
with: | |
python-version: "3.9" | |
- name: Get the version | |
id: get_version | |
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/v/} | |
- name: Build the wheel | |
id: publish_to_pypi | |
run: | | |
python3 -m pip install --upgrade pip wheel poetry | |
python3 -m poetry config virtualenvs.in-project true | |
python3 -m poetry version ${{ steps.get_version.outputs.VERSION }} | |
python3 -m poetry build | |
- name: Publish wheel to Poetry | |
id: publish_wheel_to_poetry | |
shell: bash | |
run: python3 -m poetry publish --no-interaction | |
env: | |
POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_TOKEN }} | |
- name: Create GitHub release | |
id: create_release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: Release ${{ github.ref }} | |
draft: false | |
prerelease: false | |
- name: Upload Python wheel to the GitHub release | |
id: upload_python_wheel | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./dist/log_with_context-${{ steps.get_version.outputs.VERSION }}-py3-none-any.whl | |
asset_name: log-with-context-${{ steps.get_version.outputs.VERSION }}-py3-none-any.whl | |
asset_content_type: application/x-wheel+zip | |
- name: Upload Python tar.gz to the GitHub release | |
id: upload_python_targz | |
uses: actions/upload-release-asset@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
upload_url: ${{ steps.create_release.outputs.upload_url }} | |
asset_path: ./dist/log-with-context-${{ steps.get_version.outputs.VERSION }}.tar.gz | |
asset_name: log-with-context-${{ steps.get_version.outputs.VERSION }}.tar.gz | |
asset_content_type: application/gzip |