Add interruption events #150
Workflow file for this run
This file contains hidden or 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: CI | |
| on: push | |
| permissions: | |
| contents: read | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| name: Protobuf lint | |
| container: | |
| image: bufbuild/buf:1.45.0 | |
| steps: | |
| - name: Checkout the code | |
| uses: actions/checkout@v3 | |
| - name: lint | |
| run: buf lint | |
| - name: format | |
| run: buf format --exit-code | |
| fishjam_protos_lint: | |
| runs-on: ubuntu-latest | |
| name: CI elixir lint | |
| strategy: | |
| matrix: | |
| otp: ['27'] | |
| elixir: ['1.17'] | |
| steps: | |
| - name: Set up Elixir | |
| uses: erlef/setup-beam@v1 | |
| with: | |
| otp-version: ${{matrix.otp}} | |
| elixir-version: ${{matrix.elixir}} | |
| - name: Checkout the code | |
| uses: actions/checkout@v3 | |
| - name: Install dependencies | |
| working-directory: fishjam_protos | |
| run: mix deps.get | |
| - name: Compile without warnings | |
| working-directory: fishjam_protos | |
| id: compile | |
| run: mix compile --warnings-as-errors | |
| - name: Check formatting | |
| working-directory: fishjam_protos | |
| if: ${{ !cancelled() && steps.compile.outcome == 'success' }} | |
| run: mix format --check-formatted | |
| check-fishjam-protos-update: | |
| runs-on: ubuntu-latest | |
| name: Fishjam protos update | |
| strategy: | |
| matrix: | |
| otp: ['27'] | |
| elixir: ['1.17'] | |
| steps: | |
| - name: Set up Elixir | |
| uses: erlef/setup-beam@v1 | |
| with: | |
| otp-version: ${{matrix.otp}} | |
| elixir-version: ${{matrix.elixir}} | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Install protobuf compiler (protoc) | |
| run: | | |
| sudo apt update | |
| sudo apt install -y protobuf-compiler | |
| PATH=~/.mix/escripts:$PATH | |
| mix deps.get | |
| mix escript.install hex protobuf --force | |
| working-directory: fishjam_protos | |
| - name: Run compile_proto.sh | |
| run: bash compile_proto.sh | |
| working-directory: fishjam_protos | |
| - name: Check for changes in fishjam_protos files | |
| run: | | |
| if [[ -n $(git status --porcelain) ]]; then | |
| echo "Generated protobuf files are not up to date. Please regenerate them and commit the changes." | |
| git diff | |
| exit 1 | |
| fi | |
| - name: Generate docs | |
| run: bash compile_proto.sh | |
| working-directory: fishjam_protos | |
| check-protobufs-docs: | |
| runs-on: ubuntu-latest | |
| name: Protobuf docs update | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Setup Go | |
| uses: actions/setup-go@v5 | |
| - name: Install protobuf compiler (protoc) | |
| run: | | |
| sudo apt update | |
| sudo apt install -y protobuf-compiler | |
| - name: Install protobuf docs generator | |
| run: | | |
| go install github.com/pseudomuto/protoc-gen-doc/cmd/protoc-gen-doc@latest | |
| - name: Generate docs | |
| run: | | |
| find fishjam/ -name "*.proto" | sort | xargs protoc --doc_out=./doc --doc_opt=markdown,docs.md | |
| - name: Check for changes in docs files | |
| run: | | |
| if [[ -n $(git status --porcelain) ]]; then | |
| echo "Generated docs files are not up to date. Please regenerate them and commit the changes." | |
| git diff | |
| exit 1 | |
| fi |