Skip to content

Commit

Permalink
[CI] Fix and switch to GitHub actions
Browse files Browse the repository at this point in the history
  • Loading branch information
banach-space committed Jul 6, 2024
1 parent 1897401 commit fafb54e
Show file tree
Hide file tree
Showing 6 changed files with 80 additions and 98 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/apple-silicon.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Apple Silicon

on:
push:
pull_request:
branches: [ main ]
schedule:
- cron: '0 0 * * *'
workflow_dispatch:

jobs:
build:
runs-on: macos-latest
strategy:
matrix:
type: [Debug, Release]
steps:
- uses: actions/checkout@v4
- name: Clone GTest
run: git clone https://github.com/google/googletest.git
- name: Build and run
run: |
cd $GITHUB_WORKSPACE
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=${{ matrix.type }} ../
make -j8
./cppTutorUT
35 changes: 24 additions & 11 deletions .github/workflows/x86-ubuntu.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,33 @@
name: x86-Ubuntu

on: [push]
on:
push:
pull_request:
branches: [ main ]
schedule:
- cron: '0 0 * * *'
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
strategy:
matrix:
compiler:
- { compiler: GNU, CC: gcc-10, CXX: g++-10 }
- { compiler: LLVM, CC: clang-10, CXX: clang++-10 }
type: [Debug, Release]
steps:
- uses: actions/checkout@v1
- name: Build cpp-tutor
- uses: actions/checkout@v4
- name: Clone GTest
run: git clone https://github.com/google/googletest.git
- name: Build and run
env:
CC: ${{ matrix.compiler.CC }}
CXX: ${{ matrix.compiler.CXX }}
run: |
# CLONE GTEST
git clone https://github.com/google/googletest.git
# BUILD CPP-TUTOR
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ../
cd $GITHUB_WORKSPACE
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=${{ matrix.type }} ../
make -j8
# RUN UNIT TESTS
./cppTutorUT
27 changes: 27 additions & 0 deletions .github/workflows/x86-windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: x86-Windows

on:
push:
pull_request:
branches: [ main ]
schedule:
- cron: '0 0 * * *'
workflow_dispatch:

jobs:
build:
runs-on: windows-latest
strategy:
matrix:
type: [Debug, Release]
steps:
- uses: actions/checkout@v4
- name: Clone GTest
run: git clone https://github.com/google/googletest.git
- name: Build and run
run: |
cd $GITHUB_WORKSPACE
mkdir build && cd build
cmake -DCMAKE_BUILD_TYPE=${{ matrix.type }} ../
cmake --build .
./cppTutorUT
40 changes: 0 additions & 40 deletions .travis.yml

This file was deleted.

5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
cpp-tutor
=========
[![Build Status](https://travis-ci.org/banach-space/cpp-tutor.svg?branch=master)](https://travis-ci.org/banach-space/cpp-tutor)
[![Build status](https://ci.appveyor.com/api/projects/status/axf91gjs67eoms4s/branch/add_appveyor?svg=true)](https://ci.appveyor.com/project/banach-space/cpp-tutor/branch/add_appveyor)
[![Build Status](https://github.com/banach-space/cpp-tutor/workflows/x86/badge.svg)](https://github.com/banach-space/cpp-tutor/actions?query=workflow%3Ax86)
[![Apple Silicon](https://github.com/banach-space/cpp-tutor/actions/workflows/apple-silicon.yml/badge.svg)](https://github.com/banach-space/cpp-tutor/actions/workflows/apple-silicon.yml)
[![x86-Ubuntu](https://github.com/banach-space/cpp-tutor/actions/workflows/x86-ubuntu.yml/badge.svg)](https://github.com/banach-space/cpp-tutor/actions/workflows/x86-ubuntu.yml)

Code examples for tutoring modern C++.

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

This file was deleted.

0 comments on commit fafb54e

Please sign in to comment.