fork/wezterm

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

Wez Furlongci: bump sccache action836a0855f

termwiz-0.23.0
4.1 KiB137 linesraw
1name: fedora40_continuous
2
3on:
4  schedule:
5    - cron: "10 3 * * *"
6  push:
7    branches:
8      - main
9    paths:
10      - "**/*.rs"
11      - "**/Cargo.lock"
12      - "**/Cargo.toml"
13      - ".github/workflows/gen_fedora40_continuous.yml"
14      - "assets/fonts/**/*"
15      - "assets/icon/*"
16      - "assets/open-wezterm-here"
17      - "assets/shell-completion/**/*"
18      - "assets/shell-integration/**/*"
19      - "assets/wezterm-nautilus.py"
20      - "assets/wezterm.appdata.xml"
21      - "assets/wezterm.desktop"
22      - "ci/deploy.sh"
23      - "ci/tag-name.sh"
24      - "get-deps"
25      - "termwiz/data/wezterm.terminfo"
26
27jobs:
28  build:
29    runs-on: "ubuntu-latest"
30    container: "fedora:40"
31    env:
32      BUILD_REASON: "Schedule"
33      CARGO_INCREMENTAL: "0"
34      SCCACHE_GHA_ENABLED: "true"
35      RUSTC_WRAPPER: "sccache"
36
37    steps:
38      - name: "Install config manager"
39        shell: bash
40        run: "dnf install -y 'dnf-command(config-manager)'"
41      - name: "Install git"
42        shell: bash
43        run: "yum install -y git"
44      - name: "Install curl"
45        shell: bash
46        run: "yum install -y curl"
47      - name: "Ensure /run/sshd exists"
48        shell: bash
49        run: "mkdir -p /run/sshd"
50      - name: "Install openssh-server"
51        shell: bash
52        run: "yum install -y openssh-server"
53      - name: "Workaround git permissions issue"
54        shell: bash
55        run: "git config --global --add safe.directory /__w/wezterm/wezterm"
56      - name: "checkout repo"
57        uses: actions/checkout@v4
58        with:
59          submodules: "recursive"
60      - name: "Install Rust"
61        uses: dtolnay/rust-toolchain@stable
62      - name: "Compile with sccache"
63        uses: mozilla-actions/sccache-action@v0.0.7
64      - name: "Cache Rust Dependencies"
65        uses: actions/cache@v4
66        id: cache-cargo-vendor
67        with:
68          path: |
69            vendor
70            .cargo/config
71          key: "cargo-deps-${{ hashFiles('**/Cargo.lock') }}"
72      - name: "Vendor dependecies"
73        if: steps.cache-cargo-vendor.outputs.cache-hit != 'true'
74        shell: bash
75        run: "cargo vendor --locked --versioned-dirs >> .cargo/config"
76      - name: "Install System Deps"
77        shell: bash
78        run: "env CI=yes PATH=$PATH ./get-deps"
79      - name: "Build wezterm (Release mode)"
80        shell: bash
81        run: "cargo build -p wezterm --release"
82      - name: "Build wezterm-gui (Release mode)"
83        shell: bash
84        run: "cargo build -p wezterm-gui --release"
85      - name: "Build wezterm-mux-server (Release mode)"
86        shell: bash
87        run: "cargo build -p wezterm-mux-server --release"
88      - name: "Build strip-ansi-escapes (Release mode)"
89        shell: bash
90        run: "cargo build -p strip-ansi-escapes --release"
91      - name: "Install cargo-nextest from Cargo"
92        uses: baptiste0928/cargo-install@v3
93        with:
94          crate: "cargo-nextest"
95          cache-key: "fedora40"
96      - name: "Test"
97        shell: bash
98        run: "cargo nextest run --all --no-fail-fast"
99      - name: "Package"
100        shell: bash
101        run: "bash ci/deploy.sh"
102      - name: "Move RPM"
103        shell: bash
104        run: "mv ~/rpmbuild/RPMS/*/*.rpm wezterm-nightly-fedora40.rpm"
105      - name: "Upload artifact"
106        uses: actions/upload-artifact@v4
107        with:
108          name: "fedora40"
109          path: "wezterm-*.rpm"
110          retention-days: 5
111
112  upload:
113    runs-on: ubuntu-latest
114    needs: build
115    permissions:
116      contents: write
117      pages: write
118      id-token: write
119
120    steps:
121      - name: "Workaround git permissions issue"
122        shell: bash
123        run: "git config --global --add safe.directory /__w/wezterm/wezterm"
124      - name: "checkout repo"
125        uses: actions/checkout@v4
126      - name: "Download artifact"
127        uses: actions/download-artifact@v4
128        with:
129          name: "fedora40"
130      - name: "Checksum"
131        shell: bash
132        run: "for f in wezterm-*.rpm ; do sha256sum $f > $f.sha256 ; done"
133      - name: "Upload to Nightly Release"
134        env:
135          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
136        shell: bash
137        run: "bash ci/retry.sh gh release upload --clobber nightly wezterm-*.rpm *.sha256"