浏览代码

(tsoding#8) Copy CI from tsoding/something repo

Danil Kolumbet 5 年之前
父节点
当前提交
86e8cf574f
共有 1 个文件被更改,包括 45 次插入0 次删除
  1. 45 0
      .github/workflows/ci.yml

+ 45 - 0
.github/workflows/ci.yml

@@ -0,0 +1,45 @@
+name: CI
+on: [push, pull_request]
+
+jobs:
+  build-linux-gcc:
+    runs-on: ubuntu-18.04
+    steps:
+      - uses: actions/checkout@v1
+      - name: install dependencies
+        run: |
+          sudo apt-get update
+          sudo apt-get install -qq libsdl2-dev
+      - name: build the game
+        run: |
+          make
+        env:
+          CC: gcc
+          CXX: g++
+  build-linux-clang:
+    runs-on: ubuntu-18.04
+    steps:
+      - uses: actions/checkout@v1
+      - name: install dependencies
+        run: |
+          sudo apt-get update
+          sudo apt-get install -qq libsdl2-dev
+      - name: build the game
+        run: |
+          make
+        env:
+          CC: clang
+          CXX: clang++
+  build-macos:
+    runs-on: macOS-latest
+    steps:
+      - uses: actions/checkout@v1
+      - name: install dependencies
+        run: brew install sdl2 pkg-config
+      - name: build the game
+        run: |
+          make
+        env:
+          CC: clang
+          CXX: clang++
+  # TODO: there is no build for Windows