-
-
Notifications
You must be signed in to change notification settings - Fork 3
92 lines (85 loc) · 2.68 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
name: Build
on:
push:
paths-ignore:
- 'docs/**'
- '.github/ISSUE_TEMPLATE/**'
- '.github/*.yml'
- 'LICENSE.txt'
- '*.md'
- '*.sh'
branches:
- master
pull_request:
branches:
- master
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
env:
CTEST_OUTPUT_ON_FAILURE: 1
jobs:
check_clang_format:
name: "Check C++ style"
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Install clang
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 17
sudo apt-get install clang-format-17
- name: "Clang-format libtermbench"
run: find ./libtermbench -name "*.cpp" -o -name "*.h" | xargs clang-format-17 --Werror --dry-run
- name: "Clang-format tb1"
run: find ./tb -name "*.cpp" -o -name "*.h" | xargs clang-format-17 --Werror --dry-run
- name: "Check includes"
run: ./scripts/check-includes.sh
ubuntu_linux:
name: "Ubuntu Linux 22.04"
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- name: ccache
uses: hendrikmuhs/ccache-action@v1
with:
key: "ccache-ubuntu_2204"
max-size: 256M
- name: set environment variables
id: set_vars
run: ./scripts/ci-set-vars.sh
env:
REPOSITORY: ${{ github.event.repository.name }}
- name: "install dependencies"
run: |
set -ex
sudo apt -q update
sudo ./scripts/install-deps.sh
- name: "Install GCC 13"
run: sudo apt install g++-13
- name: "cmake"
run: cmake -S . -B build -DCMAKE_BUILD_TYPE="RelWithDebInfo" -D CMAKE_CXX_COMPILER="g++-13"
- name: "build"
run: cmake --build build/ -- -j3
- name: "install dependencies"
run: ./scripts/xvfb-deps.sh
- name: "Install contour"
run: |
wget https://github.com/contour-terminal/contour/releases/download/v0.4.3.6442/contour-0.4.3.6442-ubuntu22.04-amd64.deb
sudo dpkg -i contour-0.4.3.6442-ubuntu22.04-amd64.deb
- name: "create and patch contour.yml config file"
run: |
set -ex
mkdir -p ~/.config/contour/
contour generate config to ~/.config/contour/contour.yml
sed -i -e 's/locator: native/locator: mock/' ~/.config/contour/contour.yml
sed -i -e 's/strict_spacing: true/strict_spacing: false/' ~/.config/contour/contour.yml
cat .github/mock-font-locator.yml >> ~/.config/contour/contour.yml
cat ~/.config/contour/contour.yml
- name: "Install other terminals and dependencies"
run: sudo apt install -y kitty xterm xvfb
- name: "run benchmarks"
run: ./scripts/Xvfb-bench-run.sh
- name: "ls"
run: ls -la