Merge pull request #358 from mavlink/pr-multiple-cameras-2 #765
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: prototool | |
on: | |
push: | |
branches: | |
- 'main' | |
tags: | |
- '*' | |
pull_request: | |
branches: | |
- '*' | |
jobs: | |
prototool: | |
name: prototool linter | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Run prototool | |
run: docker run -v "$(pwd):/work" uber/prototool:1.10.0 prototool lint protos | |
deploy: | |
name: deploy | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Install prerequisites | |
run: pip install --user auditwheel twine | |
- name: Create wheel | |
working-directory: ./pb_plugins | |
run: python setup.py bdist_wheel | |
- name: Upload as CI artefact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: protoc-gen-mavsdk.whl | |
path: ./pb_plugins/dist/*.whl | |
retention-days: 2 | |
- name: Deploy to PyPi | |
env: | |
TWINE_USERNAME: ${{ secrets.TWINE_USERNAME }} | |
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }} | |
TWINE_NON_INTERACTIVE: 1 | |
if: startsWith(github.ref, 'refs/tags/') | |
run: | | |
export PATH=$PATH:$HOME/.local/bin | |
twine upload ./pb_plugins/dist/*.whl |