Skip to content

Commit

Permalink
feat(ci): Add format ci.
Browse files Browse the repository at this point in the history
  • Loading branch information
KuangjuX committed May 15, 2024
1 parent a88367f commit c2b1896
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 1 deletion.
25 changes: 25 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Build CI

on: [push, pull_request]

jobs:
clippy:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
rust-toolchain: [stable]
steps:
- uses: actions/checkout@v2
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust-toolchain }}
components: clippy, rust-src, rustfmt
override: true
- name: Check rust version
run: rustc --version --verbose
- name: Run Clippy
run: cargo clippy --all-targets --all-features -- -D warnings
- name: Check code formatting
run: cargo fmt --all -- --check
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
EXAMPLE ?= shared_block
EXAMPLE ?= global_block

.PHONY: build test clean example

Expand Down
1 change: 1 addition & 0 deletions thriller-core/src/engine/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ impl ThrillerEngine {
pub fn emit_dataflow<T: AsRef<str>>(&self, sig: T) -> ThrillerResult<String> {
let mut code = String::new();
code += self.emit_function_signature(sig)?.as_str();

code += "{\n";
code += "// Declare shared memory buffer\n";
code += Memory::emit_shared_buf_decl().as_str();
Expand Down

0 comments on commit c2b1896

Please sign in to comment.