Skip to content

Commit

Permalink
Add Github Actions CI workflow.
Browse files Browse the repository at this point in the history
From what I understand, TravisCI no longer offer CI for open source projects without jumping through a lot of hoops to obtain free credits.
  • Loading branch information
teymour-aldridge committed Nov 10, 2021
1 parent f8b1036 commit 0826ada
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 10 deletions.
41 changes: 41 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Tests

on:
pull_request:
push:
branches:
- "master"

jobs:
format_and_lint:
name: Format and lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install latest nightly
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
components: rustfmt, clippy
- uses: Swatinem/rust-cache@v1
- name: Check formating
run: cargo fmt -- --check
- name: Lint
run: cargo clippy -- -D warnings
test:
runs-on: ubuntu-latest
strategy:
matrix:
rust_version: [1.36.0, stable, beta, nightly]
fail-fast: false
steps:
- uses: actions/checkout@v2
- name: Install latest nightly
uses: actions-rs/toolchain@v1
with:
toolchain: ${{matrix.rust_version}}
override: true
- uses: Swatinem/rust-cache@v1
- name: Test
run: cargo test
10 changes: 0 additions & 10 deletions .travis.yml

This file was deleted.

0 comments on commit 0826ada

Please sign in to comment.