fork/wezterm

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

Wez Furlongci: bump sccache action836a0855f

termwiz-0.23.0
3.3 KiB118 linesraw
1name: windows_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_windows_continuous.yml"
14      - "assets/fonts/**/*"
15      - "assets/icon/*"
16      - "assets/windows/**/*"
17      - "ci/deploy.sh"
18      - "ci/windows-installer.iss"
19
20jobs:
21  build:
22    runs-on: "windows-latest"
23    
24    env:
25      BUILD_REASON: "Schedule"
26      CARGO_INCREMENTAL: "0"
27      SCCACHE_GHA_ENABLED: "true"
28      RUSTC_WRAPPER: "sccache"
29      RUSTUP_WINDOWS_PATH_ADD_BIN: "1"
30
31    steps:
32      - name: "checkout repo"
33        uses: actions/checkout@v4
34        with:
35          submodules: "recursive"
36      - name: "Install Rust"
37        uses: dtolnay/rust-toolchain@stable
38        with:
39          target: "x86_64-pc-windows-msvc"
40      - name: "Compile with sccache"
41        uses: mozilla-actions/sccache-action@v0.0.7
42      - name: "Cache Rust Dependencies"
43        uses: actions/cache@v4
44        id: cache-cargo-vendor
45        with:
46          path: |
47            vendor
48            .cargo/config
49          key: "cargo-deps-${{ hashFiles('**/Cargo.lock') }}"
50      - name: "Vendor dependecies"
51        if: steps.cache-cargo-vendor.outputs.cache-hit != 'true'
52        shell: bash
53        run: "cargo vendor --locked --versioned-dirs >> .cargo/config"
54      - name: "Build wezterm (Release mode)"
55        shell: cmd
56        run: |
57          PATH C:\Strawberry\perl\bin;%PATH%
58          cargo build -p wezterm --release
59      - name: "Build wezterm-gui (Release mode)"
60        shell: cmd
61        run: |
62          PATH C:\Strawberry\perl\bin;%PATH%
63          cargo build -p wezterm-gui --release
64      - name: "Build wezterm-mux-server (Release mode)"
65        shell: cmd
66        run: |
67          PATH C:\Strawberry\perl\bin;%PATH%
68          cargo build -p wezterm-mux-server --release
69      - name: "Build strip-ansi-escapes (Release mode)"
70        shell: cmd
71        run: |
72          PATH C:\Strawberry\perl\bin;%PATH%
73          cargo build -p strip-ansi-escapes --release
74      - name: "Install cargo-nextest from Cargo"
75        uses: baptiste0928/cargo-install@v3
76        with:
77          crate: "cargo-nextest"
78          cache-key: "windows"
79      - name: "Test"
80        shell: cmd
81        run: |
82          PATH C:\Strawberry\perl\bin;%PATH%
83          cargo nextest run --all --no-fail-fast
84      - name: "Package"
85        shell: bash
86        run: "bash ci/deploy.sh"
87      - name: "Upload artifact"
88        uses: actions/upload-artifact@v4
89        with:
90          name: "windows"
91          path: |
92            WezTerm-*.zip
93            WezTerm-*.exe
94          retention-days: 5
95
96  upload:
97    runs-on: ubuntu-latest
98    needs: build
99    permissions:
100      contents: write
101      pages: write
102      id-token: write
103
104    steps:
105      - name: "checkout repo"
106        uses: actions/checkout@v4
107      - name: "Download artifact"
108        uses: actions/download-artifact@v4
109        with:
110          name: "windows"
111      - name: "Checksum"
112        shell: bash
113        run: "for f in WezTerm-*.zip WezTerm-*.exe ; do sha256sum $f > $f.sha256 ; done"
114      - name: "Upload to Nightly Release"
115        env:
116          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
117        shell: bash
118        run: "bash ci/retry.sh gh release upload --clobber nightly WezTerm-*.zip WezTerm-*.exe *.sha256"