Remove copy-pasted server references #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test and build | |
on: push | |
env: | |
RUSTFLAGS: "-Dwarnings" | |
jobs: | |
test: | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Pull repo | |
uses: actions/checkout@v4 | |
- name: Check | |
if: ${{ success() }} | |
run: cargo check --all-targets --all-features | |
- name: Run clippy | |
if: ${{ success() }} | |
run: cargo clippy --all-targets --all-features | |
build-linux: | |
runs-on: ubuntu-22.04 | |
needs: test | |
steps: | |
- name: Pull repo | |
uses: actions/checkout@v4 | |
- name: Build | |
if: ${{ success() }} | |
run: cargo build --release | |
- name: Move build artifacts | |
if: ${{ success() }} | |
run: mv target/release/proxy . | |
- name: Pack build artifacts and extra data | |
if: ${{ success() }} | |
run: tar --zstd -cf proxy.tar.zst proxy proxy.toml | |
- name: Upload artifact | |
if: ${{ success() }} | |
uses: actions/upload-artifact@v4 | |
with: | |
name: x86_64-linux-proxy.tar.zst | |
path: ./proxy.tar.zst | |
crossbuild-windows: | |
runs-on: ubuntu-22.04 | |
needs: test | |
steps: | |
- name: Pull repo | |
uses: actions/checkout@v4 | |
- name: Install MinGw | |
if: ${{ success() }} | |
uses: egor-tensin/setup-mingw@v2 | |
with: | |
cc: 0 | |
- name: Install windows target | |
if: ${{ success() }} | |
run: rustup target add x86_64-pc-windows-gnu | |
- name: Build | |
if: ${{ success() }} | |
run: cargo build --target x86_64-pc-windows-gnu --release | |
- name: Move build artifacts | |
if: ${{ success() }} | |
run: mv target/x86_64-pc-windows-gnu/release/proxy.exe . | |
- name: Pack build artifacts and extra data | |
if: ${{ success() }} | |
run: 7z a -mx9 proxy.7z proxy.exe proxy.toml | |
- name: Upload artifact | |
if: ${{ success() }} | |
uses: actions/upload-artifact@v4 | |
with: | |
name: x86_64-mingw-proxy.7z | |
path: ./proxy.7z | |
build-windows: | |
runs-on: windows-2022 | |
needs: test | |
steps: | |
- name: Pull repo | |
uses: actions/checkout@v4 | |
- name: Build | |
if: ${{ success() }} | |
run: cargo build --release | |
- name: Move build artifacts | |
if: ${{ success() }} | |
run: move target/release/proxy.exe . | |
- name: Pack build artifacts and extra data | |
if: ${{ success() }} | |
run: 7z a -mx9 proxy.7z proxy.exe proxy.toml | |
- name: Upload artifact | |
if: ${{ success() }} | |
uses: actions/upload-artifact@v4 | |
with: | |
name: x86_64-windows-proxy.7z | |
path: ./proxy.7z |