Bump the github-actions group with 3 updates #165
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: Continuous Integration | |
on: [push, pull_request] | |
permissions: | |
contents: read | |
packages: write | |
env: | |
REGISTRY: ghcr.io | |
IMAGE_NAME: ${{ github.repository }} | |
BUILD_TYPE: Release | |
jobs: | |
clang-format: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: clang-format | |
uses: jidicula/clang-format-action@4726374d1aa3c6aecf132e5197e498979588ebc8 # v4.15.0 | |
with: | |
clang-format-version: '17' | |
check-path: 'src' | |
fallback-style: 'Google' | |
include-regex: '^.*\.((((c|C)(c|pp|xx|\+\+)?$)|((h|H)h?(pp|xx|\+\+)?$))|(frag|vert))$' | |
build-dpcpp-nightly: | |
runs-on: ubuntu-latest | |
services: | |
registry: | |
image: registry:2.8.3@sha256:a3d8aaa63ed8681a604f1dea0aa03f100d5895b6a58ace528858a7b332415373 | |
ports: | |
- 5000:5000 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
submodules: 'recursive' | |
- name: Path filter | |
uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2 | |
id: changes | |
with: | |
filters: | | |
container: | |
- 'ci/Dockerfile' | |
- name: Set up Docker Buildx | |
if: steps.changes.outputs.container == 'true' | |
uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0 | |
with: | |
driver-opts: network=host | |
- name: Log in to the Container registry | |
if: steps.changes.outputs.container == 'false' || github.event_name == 'push' | |
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4.0 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Extract metadata | |
if: steps.changes.outputs.container == 'false' || github.event_name == 'push' | |
id: meta | |
uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7.0 | |
with: | |
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} | |
tags: | | |
# push latest tag on main branch push | |
type=raw,value=latest,enable=${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }},priority=5000 | |
# push branch name as the tag for every other branch push | |
type=raw,value=${{github.ref_name}},enable=${{ github.event_name == 'push' && github.ref != 'refs/heads/main' }},priority=4000 | |
# pull latest in PRs | |
type=raw,value=latest,enable=${{ github.event_name != 'push' }},priority=3000 | |
- name: Build and push image | |
if: steps.changes.outputs.container == 'true' && github.event_name == 'push' | |
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
with: | |
context: '{{defaultContext}}:ci' | |
push: true | |
tags: ${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} | |
- name: Build local image | |
if: steps.changes.outputs.container == 'true' && github.event_name != 'push' | |
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
with: | |
context: '{{defaultContext}}:ci' | |
push: true | |
tags: localhost:5000/sycl-samples:local | |
labels: ${{ steps.meta.outputs.labels }} | |
- name: CMake configure and build | |
run: | | |
if [[ "${{steps.changes.outputs.container}}" == "false" || "${{github.event_name}}" == "push" ]]; then IMAGE_TAG=${{steps.meta.outputs.tags}}; else IMAGE_TAG=localhost:5000/sycl-samples:local; fi | |
docker run -v${{github.workspace}}:/work ${IMAGE_TAG} ${{env.BUILD_TYPE}} | |
build-oneapi-basekit-nographics: | |
runs-on: ubuntu-latest | |
container: | |
image: intel/oneapi-basekit:latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: Configure CMake (no graphics) | |
run: > | |
cmake -B ${{github.workspace}}/build | |
-DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} | |
-DCMAKE_CXX_COMPILER=icpx | |
-DENABLE_GRAPHICS=OFF | |
-DENABLE_SPIR=ON -DENABLE_CUDA=OFF -DENABLE_HIP=OFF | |
-DCMAKE_CXX_FLAGS='-Wall -Wextra -Wpedantic -Werror' | |
- name: Build (no graphics) | |
run: cmake --build ${{github.workspace}}/build -- -k -j |