aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--.github/workflows/tests.yml17
-rw-r--r--.github/workflows/uml.yml51
2 files changed, 17 insertions, 51 deletions
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
new file mode 100644
index 0000000..ba20abc
--- /dev/null
+++ b/.github/workflows/tests.yml
@@ -0,0 +1,17 @@
+name: Tests
+
+on:
+ pull_request:
+
+jobs:
+ test:
+ runs-on: ubuntu-latest
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ ref: ${{ github.head_ref }}
+
+ - uses: cachix/install-nix-action@v27
+
+ - name: Run tests
+ run: nix develop --command dune test
diff --git a/.github/workflows/uml.yml b/.github/workflows/uml.yml
deleted file mode 100644
index 2d946e8..0000000
--- a/.github/workflows/uml.yml
+++ /dev/null
@@ -1,51 +0,0 @@
-name: UML
-
-on:
- pull_request:
-
-permissions:
- contents: write
-
-jobs:
- blueprint:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- with:
- ref: ${{ github.head_ref }}
-
- - uses: cachix/install-nix-action@v27
-
- - name: Run tests
- run: nix develop --command dune test
-
- - name: Generate blueprint
- run: |
- nix shell nixpkgs#perl --command \
- perl tools/uml_blueprint.pl --src lib --out docs/architecture.puml --strict --no-notes
-
- - name: Render diagram
- run: |
- nix shell nixpkgs#plantuml --command \
- plantuml -tsvg docs/architecture.puml
-
- - name: Upload artifact
- uses: actions/upload-artifact@v4
- with:
- name: architecture-diagram
- path: |
- docs/architecture.puml
- docs/architecture.svg
-
- - name: Commit diagram to the PR branch
- if: github.event.pull_request.head.repo.full_name == github.repository
- run: |
- git config user.name "github-actions[bot]"
- git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
- git add docs/architecture.puml docs/architecture.svg
- if git diff --cached --quiet; then
- echo "unchanged"
- else
- git commit -m "ci: update architecture diagram [skip ci]"
- git push origin HEAD:${{ github.head_ref }}
- fi