Skip to content

Add DSO commit check #19

Add DSO commit check

Add DSO commit check #19

Workflow file for this run

name: Check
on:
push:
pull_request:
# branches: [ "master" ]
jobs:
commit-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: commit-check/commit-check-action@v1
with:
message: true
branch: true
author-name: true
author-email: true
commit-signoff: true
dry-run: true
job-summary: true
check:
runs-on: ubuntu-latest
steps:
- name: Check out source code
- uses: actions/checkout@v4
with:
fetch-depth: 0
# - name: Check commit
# - uses: commit-check/commit-check-action@v1
# with:
# message: false
# branch: false
# author-name: true
# author-email: true
# commit-signoff: true
# dry-run: false
# job-summary: true
- name: Get swayimg version
run: echo "VERSION=$(git describe --tags --long --always | sed 's/^v//;s/-/./')" >> $GITHUB_OUTPUT
id: version
- name: Build docker image
run: docker build --tag swayimg .github/workflows
- name: Run docker container
run: docker run --tty --detach --name=swayimg --volume=$PWD:$PWD:ro --workdir=$PWD swayimg
- name: Configure
run: docker exec swayimg meson setup -Dversion=${{steps.version.outputs.VERSION}} -Dtests=enabled --prefix=/usr /tmp/build
- name: Compile and link
run: docker exec swayimg ninja -C /tmp/build
- name: Install
run: docker exec swayimg env DESTDIR=/tmp/install ninja -C /tmp/build install
- name: Run installed
run: docker exec swayimg /tmp/install/usr/bin/swayimg --version
- name: Run unit tests
run: docker exec swayimg meson test --verbose -C /tmp/build