Skip to content

Merge pull request #149 from zonble/master #527

Merge pull request #149 from zonble/master

Merge pull request #149 from zonble/master #527

Workflow file for this run

name: CI
on: [push, pull_request]
jobs:
build_debian_based:
strategy:
fail-fast: false
matrix:
os:
[
"ubuntu:22.04",
"ubuntu:24.04",
"ubuntu:24.10",
"debian:12",
"linuxmintd/mint22-amd64",
"linuxmintd/mint21-amd64",
]
runs-on: ubuntu-latest
container: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: |
export DEBIAN_FRONTEND=noninteractive
apt-get update
apt install -y pkg-config
apt install -y clang
apt install -y cmake extra-cmake-modules gettext libfmt-dev
apt install -y fcitx5 libfcitx5core-dev libfcitx5config-dev libfcitx5utils-dev fcitx5-modules-dev
apt install -y libjson-c-dev
- name: Install Build Essential
if: matrix.os == 'ubuntu:24.10'
run: |
apt install -y build-essential
- name: Build
run: |
mkdir -p build
cd build
cmake ../ -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Debug
make -j
cd ../
mkdir -p src/Engine/build
cd src/Engine/build
cmake ../
make -j
- name: Test
run: |
cd build
ctest --output-on-failure
build_debian_based_legacy:
strategy:
fail-fast: false
matrix:
os: ["ubuntu:20.04", "linuxmintd/mint20-amd64"]
runs-on: ubuntu-latest
container: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: |
export DEBIAN_FRONTEND=noninteractive
apt-get update
apt install -y pkg-config
apt install -y clang
apt install -y cmake extra-cmake-modules gettext libfmt-dev
apt install -y fcitx5 libfcitx5core-dev libfcitx5config-dev libfcitx5utils-dev fcitx5-modules-dev
apt install -y libicu-dev libjson-c-dev
- name: Build
run: |
mkdir -p build
cd build
cmake ../ -DCMAKE_INSTALL_PREFIX=/usr -DUSE_LEGACY_FCITX5_API=1 -DCMAKE_BUILD_TYPE=Debug
make -j
- name: Test
run: |
cd build
ctest --output-on-failure
build_archlinux:
runs-on: ubuntu-latest
container: ghcr.io/xatier/arch-dev:latest
steps:
- name: Checkout
run: |
export HOME=/home/xatier
cd /home/xatier
echo "cloning $GITHUB_SERVER_URL/$GITHUB_REPOSITORY into $PWD $GITHUB_SHA"
git clone "$GITHUB_SERVER_URL/$GITHUB_REPOSITORY"
cd /home/xatier/fcitx5-mcbopomofo
git fetch origin "$GITHUB_REF" ||:
git checkout "$GITHUB_SHA"
- name: Build
run: |
export HOME=/home/xatier
cd /home/xatier/fcitx5-mcbopomofo/distro/archlinux/
sudo pacman -Syy
makepkg -s --noconfirm