Skip to content

Commit

Permalink
Make separate workflow for each build config
Browse files Browse the repository at this point in the history
This will enable us to give each config its own badge.  We can display
these badges prominently on our README file.  We can also add them to
the new page we'll add which clarifies which configurations we support.
  • Loading branch information
chiphogg committed Jul 26, 2023
1 parent e608c72 commit 94353a5
Show file tree
Hide file tree
Showing 4 changed files with 88 additions and 9 deletions.
16 changes: 7 additions & 9 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,17 @@
name: build-and-test

on:
push:
branches:
- main
pull_request:
workflow_call:
inputs:
config:
required: true
type: string

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
config: ["clang11", "clang14", "gcc10"]

steps:
- uses: actions/checkout@dc323e67f16fb5f7663d20ff7941f27f5809e9b6 #v2.6.0
- name: Build and test (${{ matrix.config }})
run: bazel test --copt=-Werror --config=${{ matrix.config }} //...:all
- name: Build and test (${{ inputs.config }})
run: bazel test --copt=-Werror --config=${{ inputs.config }} //...:all
27 changes: 27 additions & 0 deletions .github/workflows/clang11-ubuntu.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Copyright 2023 Aurora Operations, Inc.
#
# 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: clang11-ubuntu

on:
push:
branches:
- main
pull_request:

jobs:
build:
uses: ./.github/workflows/build-and-test.yml
with:
config: clang11
27 changes: 27 additions & 0 deletions .github/workflows/clang14-ubuntu.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Copyright 2023 Aurora Operations, Inc.
#
# 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: clang14-ubuntu

on:
push:
branches:
- main
pull_request:

jobs:
build:
uses: ./.github/workflows/build-and-test.yml
with:
config: clang14
27 changes: 27 additions & 0 deletions .github/workflows/gcc10-ubuntu.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Copyright 2023 Aurora Operations, Inc.
#
# 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: gcc10-ubuntu

on:
push:
branches:
- main
pull_request:

jobs:
build:
uses: ./.github/workflows/build-and-test.yml
with:
config: gcc10

0 comments on commit 94353a5

Please sign in to comment.