Skip to content

cmake 4.3 (#21)

cmake 4.3 (#21) #200

Workflow file for this run

name: ci
on:
push:
branches:
- master
tags:
- '[0-9]+.*'
pull_request:
workflow_dispatch:
jobs:
lint:
runs-on: macos-26
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: '3.14'
- name: Install dependencies
run: |
brew install swift-format
pip install pyright ruff
- name: Lint
run: ./scripts/lint.sh
build:
needs: lint
runs-on: macos-26
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v6
with:
submodules: true
- uses: actions/setup-python@v6
with:
python-version: '3.14'
- name: Install dependencies
run: |
pip install requests
- name: Get tag
run: |
if [[ ${{ github.event_name }} != 'pull_request' && ${{ github.ref }} != 'refs/heads/master' ]]; then
echo "tag=${{ github.ref_name }}" >> "$GITHUB_ENV"
else
echo "tag=latest" >> "$GITHUB_ENV"
fi
- name: Build vanilla edition
run: |
python package.py $tag
mv build/universal/src/Fcitx5Installer.zip .
rm -rf build/universal
- name: Build Pinyin edition
run: |
python package.py $tag 拼音版 chinese-addons,lua pinyin true
mv build/universal/src/Fcitx5Installer.zip Fcitx5-Pinyin.zip
rm -rf build/universal
- name: Build Rime edition
run: |
python package.py $tag 中州韵版 rime rime true
mv build/universal/src/Fcitx5Installer.zip Fcitx5-Rime.zip
rm -rf build/universal
- name: Build Japanese edition
run: |
python package.py $tag 日本語版 mozc mozc true
mv build/universal/src/Fcitx5Installer.zip Fcitx5-Japanese.zip
rm -rf build/universal
- name: Upload artifact
if: ${{ github.event_name == 'pull_request' }}
uses: actions/upload-artifact@v6
with:
name: artifact
path: |
*.zip
- name: Release
if: ${{ github.event_name != 'pull_request' }}
uses: 'marvinpinto/action-automatic-releases@latest'
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
automatic_release_tag: ${{ github.ref == 'refs/heads/master' && 'latest' || github.ref_name }}
prerelease: ${{ github.ref == 'refs/heads/master' }}
title: ${{ github.ref == 'refs/heads/master' && 'Nightly Build' || github.ref_name }}
files: |
Fcitx5Installer.zip
Fcitx5-Pinyin.zip
Fcitx5-Rime.zip
Fcitx5-Japanese.zip
- name: Setup tmate session
if: ${{ failure() }}
uses: mxschmitt/action-tmate@v3