fork/wezterm

git clone https://git.julia.blue/fork/wezterm

Wez Furlongci: trigger builds when .cargo/config.toml changes7d0bff069

termiz-0.23.1
3.4 KiB112 linesraw
1name: ubuntu22.04
2
3on:
4  pull_request:
5    branches:
6      - main
7    paths:
8      - "**/*.rs"
9      - "**/Cargo.lock"
10      - "**/Cargo.toml"
11      - ".cargo/config.toml"
12      - ".github/workflows/gen_ubuntu22.04.yml"
13      - "assets/fonts/**/*"
14      - "assets/icon/*"
15      - "assets/open-wezterm-here"
16      - "assets/shell-completion/**/*"
17      - "assets/shell-integration/**/*"
18      - "assets/wezterm-nautilus.py"
19      - "assets/wezterm.appdata.xml"
20      - "assets/wezterm.desktop"
21      - "ci/deploy.sh"
22      - "ci/tag-name.sh"
23      - "get-deps"
24      - "termwiz/data/wezterm.terminfo"
25
26jobs:
27  build:
28    runs-on: "ubuntu-latest"
29    container: "ubuntu:22.04"
30    env:
31      CARGO_INCREMENTAL: "0"
32      SCCACHE_GHA_ENABLED: "true"
33      RUSTC_WRAPPER: "sccache"
34
35    steps:
36      - name: "set APT to non-interactive"
37        shell: bash
38        run: "echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections"
39      - name: "Update APT"
40        shell: bash
41        run: "apt update"
42      - name: "Install git"
43        shell: bash
44        run: "apt-get install -y git"
45      - name: "Install curl"
46        shell: bash
47        run: "apt-get install -y curl"
48      - name: "Update APT"
49        shell: bash
50        run: "apt update"
51      - name: "Ensure /run/sshd exists"
52        shell: bash
53        run: "mkdir -p /run/sshd"
54      - name: "Install openssh-server"
55        shell: bash
56        run: "apt-get install -y openssh-server"
57      - name: "Workaround git permissions issue"
58        shell: bash
59        run: "git config --global --add safe.directory /__w/wezterm/wezterm"
60      - name: "checkout repo"
61        uses: actions/checkout@v4
62        with:
63          submodules: "recursive"
64      - name: "Install Rust"
65        uses: dtolnay/rust-toolchain@stable
66      - name: "Compile with sccache"
67        uses: mozilla-actions/sccache-action@v0.0.7
68      - name: "Cache Rust Dependencies"
69        uses: actions/cache@v4
70        id: cache-cargo-vendor
71        with:
72          path: |
73            vendor
74            .cargo/config
75          key: "cargo-deps-${{ hashFiles('**/Cargo.lock') }}"
76      - name: "Vendor dependecies"
77        if: steps.cache-cargo-vendor.outputs.cache-hit != 'true'
78        shell: bash
79        run: "cargo vendor --locked --versioned-dirs >> .cargo/config"
80      - name: "Install System Deps"
81        shell: bash
82        run: "env CI=yes PATH=$PATH ./get-deps"
83      - name: "Build wezterm (Release mode)"
84        shell: bash
85        run: "cargo build -p wezterm --release"
86      - name: "Build wezterm-gui (Release mode)"
87        shell: bash
88        run: "cargo build -p wezterm-gui --release"
89      - name: "Build wezterm-mux-server (Release mode)"
90        shell: bash
91        run: "cargo build -p wezterm-mux-server --release"
92      - name: "Build strip-ansi-escapes (Release mode)"
93        shell: bash
94        run: "cargo build -p strip-ansi-escapes --release"
95      - name: "Install cargo-nextest from Cargo"
96        uses: baptiste0928/cargo-install@v3
97        with:
98          crate: "cargo-nextest"
99          cache-key: "ubuntu22.04"
100      - name: "Test"
101        shell: bash
102        run: "cargo nextest run --all --no-fail-fast"
103      - name: "Package"
104        shell: bash
105        run: "bash ci/deploy.sh"
106      - name: "Upload artifact"
107        uses: actions/upload-artifact@v4
108        with:
109          name: "ubuntu22.04"
110          path: |
111            wezterm-*.deb
112            wezterm-*.xz