Debian Codegraph @

.github/workflows/check.yml

raw
1 name: CI
2 on:
3 push:
4 branches:
5 - master
6 pull_request:
7 branches:
8 - master
9 jobs:
10 clang-format:
11 name: Check clang-format
12 runs-on: ubuntu-latest
13 container: archlinux:latest
14 steps:
15 - name: Install dependencies
16 run: |
17 pacman -Syu --noconfirm git clang diffutils
18 git config --global --add safe.directory $GITHUB_WORKSPACE
19 - uses: actions/checkout@v4
20 - uses: fcitx/github-actions@clang-format
21 check:
22 name: Build and test
23 needs: clang-format
24 runs-on: ubuntu-latest
25 container: archlinux:latest
26 strategy:
27 fail-fast: false
28 matrix:
29 compiler: [gcc, clang]
30 include:
31 - compiler: gcc
32 cxx_compiler: g++
33 - compiler: clang
34 cxx_compiler: clang++
35 env:
36 CC: ${{ matrix.compiler }}
37 CXX: ${{ matrix.cxx_compiler }}
38 steps:
39 - name: Install dependencies
40 run: |
41 pacman -Syu --noconfirm base-devel clang cmake ninja extra-cmake-modules fmt libuv boost git qt6-base qt6-wayland libxkbcommon libskk skk-jisyo
42 - uses: actions/checkout@v4
43 with:
44 repository: fcitx/fcitx5
45 path: fcitx5
46 - name: Cache fcitx5 data files
47 uses: actions/cache@v4
48 with:
49 path: 'fcitx5/**/*.tar.*'
50 key: ${{ runner.os }}-${{ hashFiles('fcitx5/src/modules/spell/CMakeLists.txt') }}
51 - name: Build and Install fcitx5
52 uses: fcitx/github-actions@cmake
53 with:
54 path: fcitx5
55 cmake-option: >-
56 -DENABLE_KEYBOARD=Off -DENABLE_X11=Off -DENABLE_WAYLAND=Off -DENABLE_ENCHANT=Off
57 -DENABLE_DBUS=Off -DENABLE_SERVER=Off -DENABLE_EMOJI=Off -DUSE_SYSTEMD=Off -DENABLE_TEST=Off
58 - uses: actions/checkout@v4
59 with:
60 repository: fcitx/fcitx5-qt
61 path: fcitx5-qt
62 - name: Build and Install fcitx5-qt
63 uses: fcitx/github-actions@cmake
64 with:
65 path: fcitx5-qt
66 cmake-option: >-
67 -DENABLE_QT4=Off -DENABLE_QT5=Off -DENABLE_QT6=On
68 - uses: actions/checkout@v4
69 with:
70 path: fcitx5-skk
71 - name: Init CodeQL
72 uses: github/codeql-action/init@v3
73 with:
74 languages: cpp
75 source-root: fcitx5-skk
76 - name: Build and Install fcitx5-skk
77 uses: fcitx/github-actions@cmake
78 with:
79 path: fcitx5-skk
80 - name: Test
81 run: |
82 ctest --test-dir fcitx5-skk/build
83 - name: CodeQL Analysis
84 uses: github/codeql-action/analyze@v2