Skip to content

Commit

Permalink
ci: adds continuous integration workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
claymcleod committed Sep 5, 2024
1 parent d20d8de commit 63f6139
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
52 changes: 52 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: CI

on:
push:
branches:
- main
pull_request:

jobs:
format:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Update Rust
run: rustup update nightly && rustup default nightly
- name: Install rustfmt
run: rustup component add rustfmt
- run: cargo fmt -- --check

lint:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Update Rust
run: rustup update stable && rustup default stable
- name: Install clippy
run: rustup component add clippy
- run: cargo clippy --all-features -- --deny warnings

test:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Update Rust
run: rustup update stable && rustup default stable
- run: cargo test --all-features

test-examples:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Update Rust
run: rustup update stable && rustup default stable
- run: cargo test --all-features --examples

docs:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Update Rust
run: rustup update stable && rustup default stable
- run: cargo doc
2 changes: 2 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ pub type BoxedError = Box<dyn std::error::Error>;
/// A simple example:
///
/// ```rust
/// use crankshaft::as_into_unwrap();
///
/// /// Services that can be registered within the engine.
/// #[derive(Debug)]
/// pub enum Service {
Expand Down

0 comments on commit 63f6139

Please sign in to comment.