Skip to content

Commit

Permalink
Migrate CI from Travis and Appveyor to Github Workflows.
Browse files Browse the repository at this point in the history
  • Loading branch information
mity committed Dec 12, 2023
1 parent a27f8dc commit a9b0b45
Show file tree
Hide file tree
Showing 4 changed files with 49 additions and 70 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: Build and Test

on:
- pull_request
- push

jobs:
linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Configure
# We enforce -Wdeclaration-after-statement because Qt project needs to
# build MD4C with Integrity compiler which chokes whenever a declaration
# is not at the beginning of a block.
run: CFLAGS='--coverage -g -O0 -Wall -Wdeclaration-after-statement -Werror' cmake -DCMAKE_BUILD_TYPE=Debug -G 'Unix Makefiles' .
- name: Build
run: make VERBOSE=1
- name: Test
run: ./scripts/run-tests.sh
- name: Code Coverage Report
if: ${{ github.event_name == 'push' }}
continue-on-error: true
run: |
sudo apt-get install -y lcov
lcov --directory . --capture --output-file coverage.info
lcov --remove coverage.info '/usr/*' --output-file coverage.info
lcov --list coverage.info
bash <(curl -s https://codecov.io/bash)
windows-32:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: microsoft/setup-msbuild@v1.3.1
- name: Configure
run: cmake -DCMAKE_BUILD_TYPE=Release -G "Visual Studio 17 2022" -A Win32 .
- name: Build
run: msbuild.exe md4c.sln.sln /p:Configuration=Release /p:Platform=Win32

windows-64:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: microsoft/setup-msbuild@v1.3.1
- name: Configure
run: cmake -DCMAKE_BUILD_TYPE=Release -G "Visual Studio 17 2022" -A x64 .
- name: Build
run: msbuild.exe md4c.sln /p:Configuration=Release /p:Platform=x64
36 changes: 0 additions & 36 deletions .travis.yml

This file was deleted.

5 changes: 0 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
[![Linux Build Status (travis-ci.com)](https://img.shields.io/travis/mity/md4c/master.svg?logo=linux&label=linux%20build)](https://travis-ci.com/mity/md4c)
[![Windows Build Status (appveyor.com)](https://img.shields.io/appveyor/ci/mity/md4c/master.svg?logo=windows&label=windows%20build)](https://ci.appveyor.com/project/mity/md4c/branch/master)
[![Code Coverage Status (codecov.io)](https://img.shields.io/codecov/c/github/mity/md4c/master.svg?logo=codecov&label=code%20coverage)](https://codecov.io/github/mity/md4c)
[![Coverity Scan Status](https://img.shields.io/coverity/scan/mity-md4c.svg?label=coverity%20scan)](https://scan.coverity.com/projects/mity-md4c)


# MD4C Readme

Expand Down
29 changes: 0 additions & 29 deletions appveyor.yml

This file was deleted.

0 comments on commit a9b0b45

Please sign in to comment.