Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
83 changes: 83 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
name: CI

on:
push:
branches: ['master']
pull_request:

jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
toolchain-type: [stable]

runs-on: ${{matrix.os}}

steps:
- name: Install shaderc
if: matrix.os == 'ubuntu-latest'
run: |
wget -nv -r -nd -A install.tgz 'https://storage.googleapis.com/shaderc/badges/build_link_linux_clang_release.html'
tar xf install.tgz
export SHADERC_LIB_DIR="$PWD/install/lib"
- name: Install Ninja
if: matrix.os == 'windows-latest'
run: choco install ninja

- uses: actions/checkout@v1

- name: Test ls
run: |
pwd
ls

- uses: actions/upload-artifact@v2
with:
name: hypermine-pre
path: D:/a/hypermine/hypermine/assets/materials/00001_dirt.png

- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: ${{matrix.toolchain-type}}
override: true
- uses: actions-rs/cargo@v1
with:
command: build
args: --workspace --all-targets
- uses: actions-rs/cargo@v1
with:
command: test
args: --workspace


- uses: actions-rs/cargo@v1
with:
command: build
args: --bin client --release

- uses: actions/upload-artifact@v2
with:
name: hypermine
path: D:/a/hypermine/hypermine/target/release/client.exe

lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
components: rustfmt, clippy
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- uses: actions-rs/cargo@v1
if: always()
with:
command: clippy
args: --workspace --all-targets -- -D warnings
4 changes: 4 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ jobs:
with:
command: test
args: --workspace
- uses: actions/upload-artifact@v2
with:
name: hypermine
path: path/target/release/client*

lint:
runs-on: ubuntu-latest
Expand Down