From e066adb5d1da2c3d5038faa207c95f8503bdef79 Mon Sep 17 00:00:00 2001 From: Angelo-F Date: Sat, 20 Nov 2021 22:08:51 +0800 Subject: [PATCH] feat: add github action (namcap PKGBUILD checking) --- .github/workflows/namcap.yml | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .github/workflows/namcap.yml diff --git a/.github/workflows/namcap.yml b/.github/workflows/namcap.yml new file mode 100644 index 0000000..321f4c1 --- /dev/null +++ b/.github/workflows/namcap.yml @@ -0,0 +1,30 @@ +name: Check PKGBUILDs + +on: [push, pull_request] + +jobs: + namcap: + + runs-on: ubuntu-latest + container: + image: archlinux + + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install packages + run: | + pacman -Syu python python-pip git base-devel --noconfirm --needed + - name: Prepare namcap + run: | + git clone https://github.com/angelofallars/namcap.git + pip install --upgrade pip + pip install -r namcap/requirements.txt + - name: Install namcap + working-directory: namcap + run: python setup.py install + + - name: Check PKGBUILDs with namcap + run: | + python namcap/traverse_directory_tree.py