v0.1.3 #6
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: Publish | |
on: | |
release: | |
types: [published] | |
concurrency: | |
group: encord-agents-${{ github.ref }}-publish | |
cancel-in-progress: true | |
jobs: | |
publish: | |
name: Build and publish Encord Agents | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
token: ${{ secrets.AUTOMATION_BOT_ACCESS_TOKEN }} | |
ref: main | |
- name: Setup root poetry environment | |
uses: ./.github/actions/setup-root-poetry-environment | |
- name: Poetry Version Bump | |
run: "poetry version ${{ github.ref_name }}" | |
- name: Module Version Bump | |
run: 'sed -i "s/__version__ = \".*\"/__version__ = \"${{ github.ref_name }}\"/g" encord_agents/__init__.py' | |
- name: Version Bump commit | |
uses: stefanzweifel/git-auto-commit-action@v4 | |
with: | |
commit_message: "Version bump to ${{ github.ref_name }}" | |
push_options: --force | |
- name: Build | |
run: poetry build | |
- name: Publish | |
run: | | |
poetry config pypi-token.pypi ${{ secrets.PYPI_TOKEN }} | |
poetry publish |