From 63bf0a12baf2b5a3c6264592e6c689b29f2a400f Mon Sep 17 00:00:00 2001
From: Robert Ulmer <robert@familieulmer.info>
Date: Thu, 26 Sep 2024 17:11:14 +0200
Subject: [PATCH] workflow

---
 .github/workflows/classroom.yml | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)
 create mode 100644 .github/workflows/classroom.yml

diff --git a/.github/workflows/classroom.yml b/.github/workflows/classroom.yml
new file mode 100644
index 0000000..f1cf4be
--- /dev/null
+++ b/.github/workflows/classroom.yml
@@ -0,0 +1,29 @@
+name: Autograding Tests
+'on':
+- push
+- repository_dispatch
+permissions:
+  checks: write
+  actions: read
+  contents: read
+jobs:
+  run-autograding-tests:
+    runs-on: ubuntu-latest
+    if: github.actor != 'github-classroom[bot]'
+    steps:
+    - name: Checkout code
+      uses: actions/checkout@v4
+    - name: cmake
+      id: cmake
+      uses: classroom-resources/autograding-command-grader@v1
+      with:
+        test-name: cmake
+        setup-command: sudo apt update && sudo apt install cmake libcriterion-dev
+        command: "./build.sh -c"
+        timeout: 10
+    - name: Autograding Reporter
+      uses: classroom-resources/autograding-grading-reporter@v1
+      env:
+        CMAKE_RESULTS: "${{steps.cmake.outputs.result}}"
+      with:
+        runners: cmake