Quellcode durchsuchen

toml: add formatter and check in CI

Tamir Duberstein vor 1 Jahr
Ursprung
Commit
c8bf646ef0

+ 3 - 0
.github/workflows/lint.yml

@@ -27,6 +27,9 @@ jobs:
 
       - uses: Swatinem/rust-cache@v2
 
+      - run: cargo install taplo-cli
+      - run: taplo fmt --check
+
       - name: Check formatting
         run: cargo fmt --all -- --check
 

+ 5 - 0
.taplo.toml

@@ -0,0 +1,5 @@
+[[rule]]
+
+[rule.formatting]
+indent_string = "    "
+reorder_arrays = true

+ 1 - 1
aya-bpf-macros/Cargo.toml

@@ -10,7 +10,7 @@ proc-macro = true
 [dependencies]
 proc-macro2 = "1.0"
 quote = "1.0"
-syn = {version = "2.0", features = ["full"]}
+syn = { version = "2.0", features = ["full"] }
 
 [dev-dependencies]
 aya-bpf = { path = "../bpf/aya-bpf" }

+ 1 - 1
aya-log-common/Cargo.toml

@@ -2,7 +2,7 @@
 name = "aya-log-common"
 version = "0.1.13"
 description = "A logging library for eBPF programs."
-keywords = ["ebpf", "bpf", "log", "logging"]
+keywords = ["bpf", "ebpf", "log", "logging"]
 license = "MIT OR Apache-2.0"
 authors = ["The Aya Contributors"]
 repository = "https://github.com/aya-rs/aya-log"

+ 2 - 2
aya-log/Cargo.toml

@@ -2,7 +2,7 @@
 name = "aya-log"
 version = "0.1.13"
 description = "A logging library for eBPF programs."
-keywords = ["ebpf", "bpf", "log", "logging"]
+keywords = ["bpf", "ebpf", "log", "logging"]
 license = "MIT OR Apache-2.0"
 authors = ["The Aya Contributors"]
 repository = "https://github.com/aya-rs/aya-log"
@@ -11,7 +11,7 @@ documentation = "https://docs.rs/aya-log"
 edition = "2021"
 
 [dependencies]
-aya = { path = "../aya", version = "0.11.0", features=["async_tokio"] }
+aya = { path = "../aya", version = "0.11.0", features = ["async_tokio"] }
 aya-log-common = { path = "../aya-log-common", version = "0.1.13" }
 thiserror = "1"
 log = "0.4"

+ 0 - 1
bpf/aya-bpf-bindings/Cargo.toml

@@ -6,4 +6,3 @@ edition = "2021"
 
 [dependencies]
 aya-bpf-cty = { path = "../aya-bpf-cty" }
-

+ 1 - 1
bpf/aya-bpf-cty/Cargo.toml

@@ -1,7 +1,7 @@
 [package]
 authors = ["Jorge Aparicio <[email protected]>"]
 edition = "2021"
-categories = ["embedded", "external-ffi-bindings" ,"no-std"]
+categories = ["embedded", "external-ffi-bindings", "no-std"]
 description = "Type aliases to C types like c_int for use with bindgen"
 documentation = "https://docs.rs/cty"
 license = "MIT OR Apache-2.0"

+ 2 - 2
netlify.toml

@@ -1,3 +1,3 @@
 [build]
-  publish = "site"
-  command = "rustup toolchain install nightly -c rust-src && cargo xtask docs"
+publish = "site"
+command = "rustup toolchain install nightly -c rust-src && cargo xtask docs"

+ 0 - 1
rustfmt.toml

@@ -1,4 +1,3 @@
 unstable_features = true
 reorder_imports = true
 imports_granularity = "Crate"
-