Skip to content

Feature/rdkemw 12692 #1360

Feature/rdkemw 12692

Feature/rdkemw 12692 #1360

#
# If not stated otherwise in this file or this component's LICENSE file the
# following copyright and licenses apply:
#
# Copyright 2024 Sky UK
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
name: Protobuf breaking change detection
on:
pull_request:
branches: ["master", "release/*"]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup
uses: bufbuild/buf-setup-action@v1.31.0
- name: Set target branch
id: set-branch
run: |
if [ -n "${{ github.base_ref }}" ]; then
echo "branch=${{ github.base_ref }}" >> "$GITHUB_OUTPUT"
else
echo "branch=master" >> "$GITHUB_OUTPUT"
fi
- name: Breaking change detection against base branch
uses: bufbuild/buf-breaking-action@v1
with:
input: proto
against: "${{ github.server_url }}/${{ github.repository }}.git#branch=${{ steps.set-branch.outputs.branch }},subdir=proto"