[CI] Port CI to github actions. (#1374)

* [CI] Port CI to github actions.

* [Doc] Fix doxygen comment block.
This commit is contained in:
TonCherAmi 2021-08-20 15:54:34 +03:00 committed by GitHub
parent e60e6bab2a
commit ceee9d672a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 202 additions and 1 deletions

32
.github/actions/autotools/action.yml vendored Normal file
View file

@ -0,0 +1,32 @@
name: Autotools Build
description: Builds Rofi using Autotools
inputs:
cc:
description: Compiler to use
required: true
runs:
using: composite
steps:
- id: setup
run: |
autoreconf --install
mkdir builddir && cd builddir
../configure CC=${{ inputs.cc }}
shell: bash
- id: build
run: cd builddir && make
shell: bash
- id: test
run: cd builddir && make distcheck
shell: bash
- id: doxy
run: cd builddir && make doxy 2>&1 > doxygen.log
shell: bash
- id: doxycheck
uses: ./.github/actions/doxycheck
with:
logfile: builddir/doxygen.log

24
.github/actions/doxycheck/action.yml vendored Normal file
View file

@ -0,0 +1,24 @@
name: Doxygen Check
description: Checks for Doxygen warnings
inputs:
logfile:
description: Path to doxygen logfile
required: true
runs:
using: composite
steps:
- id: check
run: |
if [[ "$(grep -c warning ${{ inputs.logfile }})" != 0 ]]; then
echo
echo Doxygen warnings found:
grep warning ${{ inputs.logfile }}
echo
exit 1
fi
python2 ./doxy-coverage/doxy-coverage.py builddir/doc/html/xml/
shell: bash

32
.github/actions/meson/action.yml vendored Normal file
View file

@ -0,0 +1,32 @@
name: Meson Build
description: Builds Rofi using Meson
inputs:
cc:
description: Compiler to use
required: true
runs:
using: composite
steps:
- id: pip
run: pip install meson ninja
shell: bash
- id: setup
run: meson setup builddir -Db_coverage=true
shell: bash
env:
CC: ${{ inputs.cc }}
- id: build
run: ninja -C builddir
shell: bash
- id: test
run: ninja -C builddir test
shell: bash
- id: doxy
run: ninja -C builddir doc/html 2>&1 > doxygen.log
shell: bash
- id: doxycheck
uses: ./.github/actions/doxycheck
with:
logfile: doxygen.log

56
.github/actions/setup/action.yml vendored Normal file
View file

@ -0,0 +1,56 @@
name: CI Build Setup
description: Sets up build dependencies
runs:
using: composite
steps:
- id: python
uses: actions/setup-python@v1
with:
python-version: '3.x'
- id: apt
run: |
sudo apt-get install -y \
discount \
doxygen \
fluxbox \
gdb \
graphviz \
jq \
lcov \
libpango1.0-dev \
libstartup-notification0-dev \
libxcb-ewmh-dev \
libxcb-icccm4-dev \
libxcb-randr0-dev \
libxcb-util0-dev \
libxcb-xinerama0-dev \
libxcb-xkb-dev \
libxcb-xrm-dev \
libxcb-cursor-dev \
libxkbcommon-dev \
libxkbcommon-dev \
libxkbcommon-x11-dev \
ninja-build \
python3-pip \
python3-setuptools \
python3-wheel \
texi2html \
texinfo \
xdotool \
xfonts-base \
xterm \
xutils-dev
shell: bash
- id: doxy
run: git clone https://github.com/alobbs/doxy-coverage
shell: bash
- id: check
run: |
curl -L https://github.com/libcheck/check/releases/download/0.14.0/check-0.14.0.tar.gz | tar xzf -
cd check-0.14.0
./configure
make
sudo make install
sudo ldconfig
shell: bash

57
.github/workflows/build.yml vendored Normal file
View file

@ -0,0 +1,57 @@
name: CI Build
on:
push:
branches:
- next
paths-ignore:
- "**.md"
- "**.markdown"
- "**.rasi"
pull_request:
paths-ignore:
- "**.md"
- "**.markdown"
- "**.rasi"
jobs:
build-meson-gcc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- uses: ./.github/actions/setup
- uses: ./.github/actions/meson
with:
cc: gcc
build-meson-clang:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- uses: ./.github/actions/setup
- uses: ./.github/actions/meson
with:
cc: clang
build-autotools-gcc:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- uses: ./.github/actions/setup
- uses: ./.github/actions/autotools
with:
cc: gcc
build-autotools-clang:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- uses: ./.github/actions/setup
- uses: ./.github/actions/autotools
with:
cc: clang

View file

@ -295,7 +295,7 @@ void __create_window(MenuFlags menu_flags);
xcb_window_t rofi_view_get_window(void);
/** @} */
/***
/**
* @defgroup ViewThreadPool ViewThreadPool
* @ingroup View
*