summaryrefslogtreecommitdiffstats
path: root/.github/workflows/lint.yml
diff options
context:
space:
mode:
Diffstat (limited to '.github/workflows/lint.yml')
-rw-r--r--.github/workflows/lint.yml34
1 files changed, 34 insertions, 0 deletions
diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml
new file mode 100644
index 0000000..6d41378
--- /dev/null
+++ b/.github/workflows/lint.yml
@@ -0,0 +1,34 @@
+name: Lint dnbd3
+
+on:
+ push:
+ branches:
+ - master
+ pull_request:
+
+jobs:
+ lint:
+ name: Lint dnbd3
+ runs-on: ubuntu-22.04
+ steps:
+ - name: Install dnbd3 dependencies
+ run: |
+ sudo apt-get update -y -qq
+ sudo apt-get install -y -qq make \
+ clang-format \
+ linux-headers-generic \
+ libfuse-dev \
+ libjansson-dev \
+ rpm
+ - name: Checkout dnbd3 repository
+ uses: actions/checkout@v4
+ - name: Fetch dnbd3 repository tags
+ run: git fetch --prune --unshallow
+ - name: Configure dnbd3 build
+ run: |
+ cmake -B ${{ github.workspace }}/build \
+ -S ${{ github.workspace }} \
+ -D DNBD3_BENCHMARK=ON
+ - name: Lint dnbd3 artifacts
+ working-directory: ${{ github.workspace }}/build
+ run: make lint