-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from bltavares/macos
Macos
- Loading branch information
Showing
8 changed files
with
412 additions
and
378 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,31 @@ | ||
# We could use `@actions-rs/cargo` Action ability to automatically install `cross` tool | ||
# in order to compile our application for some unusual targets. | ||
|
||
on: [push, pull_request] | ||
|
||
name: Cross-compile | ||
|
||
jobs: | ||
build: | ||
name: Build | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
target: | ||
- armv7-unknown-linux-gnueabihf | ||
- powerpc64-unknown-linux-gnu | ||
- mips-unknown-linux-musl | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
target: ${{ matrix.target }} | ||
override: true | ||
- uses: actions-rs/cargo@v1 | ||
with: | ||
use-cross: true | ||
command: build | ||
args: --target=${{ matrix.target }} --examples | ||
# We could use `@actions-rs/cargo` Action ability to automatically install `cross` tool | ||
# in order to compile our application for some unusual targets. | ||
|
||
on: [push, pull_request] | ||
|
||
name: Cross-compile | ||
|
||
jobs: | ||
build: | ||
name: Build | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
target: | ||
- armv7-unknown-linux-gnueabihf | ||
- aarch64-linux-android | ||
- mips-unknown-linux-musl | ||
- x86_64-unknown-linux-musl | ||
- aarch64-unknown-linux-gnu | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
target: ${{ matrix.target }} | ||
override: true | ||
- uses: actions-rs/cargo@v1 | ||
with: | ||
use-cross: true | ||
command: build | ||
args: --target=${{ matrix.target }} --examples |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,82 +1,82 @@ | ||
# Based on https://github.com/actions-rs/meta/blob/master/recipes/quickstart.md | ||
# | ||
# While our "example" application has the platform-specific code, | ||
# for simplicity we are compiling and testing everything on the Ubuntu environment only. | ||
# For multi-OS testing see the `cross.yml` workflow. | ||
|
||
on: [push, pull_request] | ||
|
||
name: Quickstart | ||
|
||
jobs: | ||
lints: | ||
name: Lints | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install stable toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
components: rustfmt | ||
# components: rustfmt, clippy | ||
|
||
- name: Run cargo fmt | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: fmt | ||
args: --all -- --check | ||
|
||
# TODO enable clippy when unsafe calls are fixed | ||
# - name: Run cargo clippy | ||
# run: cargo clippy -- -D warnings | ||
|
||
check: | ||
name: Check | ||
runs-on: ${{matrix.os}} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macos-latest] | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install stable toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
|
||
- name: Run cargo check | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: check | ||
args: --examples | ||
|
||
test: | ||
name: Test Suite | ||
runs-on: ${{matrix.os}} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macos-latest] | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install stable toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
|
||
- name: Run cargo build | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: build | ||
args: --examples | ||
# Based on https://github.com/actions-rs/meta/blob/master/recipes/quickstart.md | ||
# | ||
# While our "example" application has the platform-specific code, | ||
# for simplicity we are compiling and testing everything on the Ubuntu environment only. | ||
# For multi-OS testing see the `cross.yml` workflow. | ||
|
||
on: [push, pull_request] | ||
|
||
name: Quickstart | ||
|
||
jobs: | ||
lints: | ||
name: Lints | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install stable toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
components: rustfmt | ||
# components: rustfmt, clippy | ||
|
||
- name: Run cargo fmt | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: fmt | ||
args: --all -- --check | ||
|
||
# TODO enable clippy when unsafe calls are fixed | ||
# - name: Run cargo clippy | ||
# run: cargo clippy -- -D warnings | ||
|
||
check: | ||
name: Check | ||
runs-on: ${{matrix.os}} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macos-latest] | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install stable toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
|
||
- name: Run cargo check | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: check | ||
args: --examples | ||
|
||
test: | ||
name: Test Suite | ||
runs-on: ${{matrix.os}} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macos-latest] | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install stable toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
|
||
- name: Run cargo build | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: build | ||
args: --examples |
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
Oops, something went wrong.