GitHub Actions: run clippy, fmt; remove other CI (#365)
Consolidates the multitude of CI systems, replacing Azure, SourceHut, and AppVeyor with GitHub Actions, which now also runs clippy and fmt. See #352 * Add task to run clippy * Add task to check formatting * Test on 1.44.1 toolchain * Update readme: status badge and downloads on GitHub Actions * Remove strip binary task, leave it unstripped to allow debugging for now * Rename task to install dependencies * Remove Azure Pipelines * Remove sr.ht SourceHut CI * Remove AppVeyor
This commit is contained in:
parent
dbca7464bd
commit
7869893038
20
.build.yml
20
.build.yml
|
@ -1,20 +0,0 @@
|
||||||
image: ubuntu/latest
|
|
||||||
packages:
|
|
||||||
- curl
|
|
||||||
- libegl1-mesa-dev
|
|
||||||
- libgles2-mesa-dev
|
|
||||||
- pkg-config
|
|
||||||
- libssl-dev
|
|
||||||
sources:
|
|
||||||
- https://github.com/iceiix/stevenarella
|
|
||||||
tasks:
|
|
||||||
- setup: |
|
|
||||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs > rustup.sh
|
|
||||||
sh ./rustup.sh -y
|
|
||||||
source $HOME/.cargo/env
|
|
||||||
cargo --version
|
|
||||||
- build: |
|
|
||||||
source $HOME/.cargo/env
|
|
||||||
cd stevenarella
|
|
||||||
cargo build
|
|
||||||
cargo test
|
|
|
@ -17,9 +17,10 @@ jobs:
|
||||||
- name: Install Rust
|
- name: Install Rust
|
||||||
uses: actions-rs/toolchain@v1
|
uses: actions-rs/toolchain@v1
|
||||||
with:
|
with:
|
||||||
toolchain: stable
|
toolchain: 1.44.1
|
||||||
|
components: clippy, rustfmt
|
||||||
default: true
|
default: true
|
||||||
- name: (Linux) Install libxcb-composite
|
- name: Install dependencies
|
||||||
if: matrix.os == 'ubuntu-latest'
|
if: matrix.os == 'ubuntu-latest'
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
|
@ -29,9 +30,13 @@ jobs:
|
||||||
cargo build --verbose --release
|
cargo build --verbose --release
|
||||||
env:
|
env:
|
||||||
MACOSX_DEPLOYMENT_TARGET: 10.14
|
MACOSX_DEPLOYMENT_TARGET: 10.14
|
||||||
- name: (Linux/MacOS) Strip binary
|
- name: Run clippy
|
||||||
if: matrix.os != 'windows-latest'
|
uses: actions-rs/clippy-check@v1.0.7
|
||||||
run: strip target/release/stevenarella
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
args: --all-targets -- -D warnings
|
||||||
|
- name: Check formatting
|
||||||
|
run: cargo fmt --all -- --check
|
||||||
- name: Move binary
|
- name: Move binary
|
||||||
run: |
|
run: |
|
||||||
if [[ ${{ matrix.os }} == windows ]]; then
|
if [[ ${{ matrix.os }} == windows ]]; then
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
# Stevenarella
|
# Stevenarella
|
||||||
[![builds.sr.ht status](https://builds.sr.ht/~iceiix/stevenarella.svg)](https://builds.sr.ht/~iceiix/stevenarella?)
|
[![Build Status](https://img.shields.io/endpoint.svg?url=https%3A%2F%2Factions-badge.atrox.dev%2Ficeiix%2Fstevenarella%2Fbadge%3Fref%3Dmaster&style=plastic)](https://actions-badge.atrox.dev/iceiix/stevenarella/goto?ref=master)
|
||||||
|
|
||||||
Multi-protocol Minecraft-compatible client written in Rust
|
Multi-protocol Minecraft-compatible client written in Rust
|
||||||
|
|
||||||
|
@ -56,8 +56,9 @@ Support for older protocols will _not_ be dropped as newer protocols are added.
|
||||||
|
|
||||||
## Downloads
|
## Downloads
|
||||||
|
|
||||||
Windows users can download pre-compiled builds from here: https://ci.appveyor.com/project/iceiix/stevenarella
|
Windows, Ubuntu Linux, and macOS users can download pre-compiled builds
|
||||||
(Select your platform, Click the artifacts tab and download Steven.zip)
|
from [GitHub Actions](https://actions-badge.atrox.dev/iceiix/stevenarella/goto?ref=master).
|
||||||
|
(Click the artifacts drop-down and select your platform.)
|
||||||
|
|
||||||
## Building
|
## Building
|
||||||
|
|
||||||
|
|
51
appveyor.yml
51
appveyor.yml
|
@ -1,51 +0,0 @@
|
||||||
version: 1.0.{build}
|
|
||||||
image: Visual Studio 2017
|
|
||||||
clone_depth: 1
|
|
||||||
skip_branch_with_pr: true
|
|
||||||
branches:
|
|
||||||
only:
|
|
||||||
- master
|
|
||||||
platform:
|
|
||||||
- x64
|
|
||||||
build_script:
|
|
||||||
- cmd: >-
|
|
||||||
echo on
|
|
||||||
|
|
||||||
echo AddMessage "PLATFORM is %PLATFORM%"
|
|
||||||
|
|
||||||
if "%PLATFORM%" == "x86" set RUST_INSTALL=i686-pc-windows-msvc
|
|
||||||
|
|
||||||
if "%PLATFORM%" == "x64" set RUST_INSTALL=x86_64-pc-windows-msvc
|
|
||||||
|
|
||||||
echo AddMessage "platform is %platform%"
|
|
||||||
|
|
||||||
appveyor AddMessage "Platform rust: %RUST_INSTALL%"
|
|
||||||
|
|
||||||
appveyor DownloadFile "https://static.rust-lang.org/dist/rust-1.44.1-%RUST_INSTALL%.exe" -FileName rust-install.exe
|
|
||||||
|
|
||||||
"./rust-install.exe" /VERYSILENT /NORESTART /DIR="C:\Rust\"
|
|
||||||
|
|
||||||
SET PATH=%PATH%;C:\Rust\bin
|
|
||||||
|
|
||||||
rustc -V
|
|
||||||
|
|
||||||
cargo -V
|
|
||||||
|
|
||||||
cargo build
|
|
||||||
|
|
||||||
mkdir dist-debug
|
|
||||||
|
|
||||||
cp target\debug\stevenarella.exe dist-debug
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
cargo build --release
|
|
||||||
|
|
||||||
mkdir dist
|
|
||||||
|
|
||||||
cp target\release\stevenarella.exe dist
|
|
||||||
|
|
||||||
|
|
||||||
artifacts:
|
|
||||||
- path: dist
|
|
||||||
- path: dist-debug
|
|
|
@ -1,17 +0,0 @@
|
||||||
jobs:
|
|
||||||
- template: default.yml@templates
|
|
||||||
parameters:
|
|
||||||
setup:
|
|
||||||
- script: sudo apt-get install libxcb-composite0-dev libx11-dev
|
|
||||||
displayName: "Install build dependencies"
|
|
||||||
condition: eq(variables['Agent.OS'], 'Linux')
|
|
||||||
minrust: 1.44.1
|
|
||||||
clippy: -D clippy::all
|
|
||||||
|
|
||||||
resources:
|
|
||||||
repositories:
|
|
||||||
- repository: templates
|
|
||||||
type: github
|
|
||||||
name: iceiix/azure-pipelines
|
|
||||||
ref: c50d2b8335a6b1856aa2fc4f5f41f6684ef8580c
|
|
||||||
endpoint: iceiix
|
|
Loading…
Reference in New Issue