diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 0000000..c081259 --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,41 @@ +name: CI + +on: [push, pull_request] +jobs: + test_musl_gcc: + name: "Test with with GCC/musl/libstdc++/BFD on Alpine Linux" + runs-on: ubuntu-latest + container: alpine:edge + steps: + - run: apk --no-cache add git gcc g++ binutils pkgconf meson ninja cmake musl-dev wayland-dev wayland-protocols libinput-dev libevdev-dev libxkbcommon-dev pixman-dev glm-dev libdrm-dev mesa-dev cairo-dev pango-dev eudev-dev libxml2-dev libseat-dev libdisplay-info-dev hwdata-dev + - name: Wayfire + uses: actions/checkout@v2 + with: + repository: WayfireWM/wayfire + path: wayfire + - run: cd wayfire && git submodule update --init --recursive && meson setup build --prefix=/usr && ninja -v -Cbuild && ninja -v -Cbuild install && cd .. + - name: Pixdecor + uses: actions/checkout@v2 + with: + repository: soreau/pixdecor + path: pixdecor + - run: cd pixdecor && meson setup build --prefix=/usr && ninja -v -C build && ninja -v -C build install && cd .. + test_code_style: + name: "Check code style with uncrustify" + runs-on: ubuntu-latest + steps: + - run: sudo apt-get update + - run: sudo apt-get install -y git cmake gcc make + - name: Build Uncrustify + uses: actions/checkout@v2 + with: + repository: ammen99/uncrustify + path: uncrustify + - run: cd uncrustify && mkdir build && cd build && cmake .. && make && cd ../.. + - name: Run Uncrustify Check + uses: actions/checkout@v2 + with: + path: pixdecor + - run: cd pixdecor && wget https://raw.githubusercontent.com/WayfireWM/wayfire/master/uncrustify.ini + - run: cd pixdecor && git ls-files | grep "hpp$\|cpp$" | xargs ../uncrustify/build/uncrustify -c uncrustify.ini --no-backup --replace + - run: cd pixdecor && git diff --exit-code