2019-12-23 22:51:22 +03:00
|
|
|
name: Build
|
|
|
|
on: [push]
|
|
|
|
jobs:
|
2019-12-27 02:52:25 +03:00
|
|
|
build-windows:
|
|
|
|
runs-on: windows-latest
|
|
|
|
if: "contains(github.event.head_commit.message, '[rebuild]')"
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@master
|
|
|
|
- uses: hecrj/setup-rust-action@v1
|
|
|
|
with:
|
2020-04-23 19:22:04 +03:00
|
|
|
rust-version: 1.43.0
|
2020-05-12 21:35:14 +03:00
|
|
|
- name: Run build
|
2019-12-27 02:52:25 +03:00
|
|
|
run: cargo build --release --bin game
|
2020-01-12 01:07:19 +03:00
|
|
|
- name: Package release
|
2020-05-12 21:35:14 +03:00
|
|
|
run: ./release/build.sh abst_windows play_abstreet.bat target/release/game.exe
|
2020-01-12 07:20:50 +03:00
|
|
|
- name: Upload binary
|
2019-12-27 02:52:25 +03:00
|
|
|
uses: actions/upload-artifact@v1
|
|
|
|
with:
|
2020-01-12 07:20:50 +03:00
|
|
|
name: game_exe
|
|
|
|
path: target/release/game.exe
|
2019-12-23 22:51:22 +03:00
|
|
|
build-macos:
|
|
|
|
runs-on: macos-latest
|
2019-12-24 02:00:22 +03:00
|
|
|
if: "contains(github.event.head_commit.message, '[rebuild]')"
|
2019-12-23 22:51:22 +03:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@master
|
|
|
|
- uses: hecrj/setup-rust-action@v1
|
|
|
|
with:
|
2020-04-23 19:22:04 +03:00
|
|
|
rust-version: 1.43.0
|
2020-05-12 21:35:14 +03:00
|
|
|
- name: Run build
|
2019-12-23 22:51:22 +03:00
|
|
|
run: cargo build --release --bin game
|
2020-01-12 01:07:19 +03:00
|
|
|
- name: Package release
|
2020-05-12 21:35:14 +03:00
|
|
|
run: ./release/build.sh abst_mac play_abstreet.sh target/release/game
|
2020-01-12 01:07:19 +03:00
|
|
|
- name: Upload release
|
2019-12-23 23:17:47 +03:00
|
|
|
uses: actions/upload-artifact@v1
|
|
|
|
with:
|
2020-01-16 22:27:15 +03:00
|
|
|
name: abst_mac
|
2020-01-22 21:44:46 +03:00
|
|
|
path: abst_mac.zip
|
2019-12-23 22:51:22 +03:00
|
|
|
build-linux:
|
|
|
|
runs-on: ubuntu-latest
|
2019-12-24 02:00:22 +03:00
|
|
|
if: "contains(github.event.head_commit.message, '[rebuild]')"
|
2019-12-23 22:51:22 +03:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@master
|
|
|
|
- uses: hecrj/setup-rust-action@v1
|
|
|
|
with:
|
2020-04-23 19:22:04 +03:00
|
|
|
rust-version: 1.43.0
|
2020-05-12 21:35:14 +03:00
|
|
|
- name: Run build
|
2019-12-23 22:51:22 +03:00
|
|
|
run: cargo build --release --bin game
|
2020-01-12 01:07:19 +03:00
|
|
|
- name: Package release
|
2020-05-12 21:35:14 +03:00
|
|
|
run: ./release/build.sh abst_linux play_abstreet.sh target/release/game
|
2020-01-12 01:07:19 +03:00
|
|
|
- name: Upload release
|
2019-12-23 23:17:47 +03:00
|
|
|
uses: actions/upload-artifact@v1
|
|
|
|
with:
|
2020-01-16 22:27:15 +03:00
|
|
|
name: abst_linux
|
2020-01-22 21:44:46 +03:00
|
|
|
path: abst_linux.zip
|