From eb843851561c5621c51b82aff1ddc4b2b69400b2 Mon Sep 17 00:00:00 2001 From: Ryu <114303361+ryuapp@users.noreply.github.com> Date: Mon, 9 Mar 2026 03:41:14 +0900 Subject: [PATCH 1/4] feat: add CI workflow --- .github/workflows/ci.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..a6d9ef6 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,17 @@ +name: CI + +on: + push: + branches: [main] + pull_request: + branches: [main] + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - uses: dtolnay/rust-toolchain@stable + - uses: Swatinem/rust-cache@v2 + - run: cargo build + - run: cargo test From af8aa51948a7243380fade79e58e5131565375cd Mon Sep 17 00:00:00 2001 From: Ryu <114303361+ryuapp@users.noreply.github.com> Date: Mon, 9 Mar 2026 03:42:06 +0900 Subject: [PATCH 2/4] feat: add cargo fmt check to CI --- .github/workflows/ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a6d9ef6..1b3ff98 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,5 +13,6 @@ jobs: - uses: actions/checkout@v6 - uses: dtolnay/rust-toolchain@stable - uses: Swatinem/rust-cache@v2 + - run: cargo fmt --check - run: cargo build - run: cargo test From 4b3b3664ae2455dd4aab5aa583c5bc4c16351681 Mon Sep 17 00:00:00 2001 From: Ryu <114303361+ryuapp@users.noreply.github.com> Date: Mon, 9 Mar 2026 03:42:38 +0900 Subject: [PATCH 3/4] feat: set minimal permissions for CI --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1b3ff98..1bc6fa1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -6,6 +6,9 @@ on: pull_request: branches: [main] +permissions: + contents: read + jobs: test: runs-on: ubuntu-latest From e143d62d552a3a865277d7e3fa8bc0231e2c4610 Mon Sep 17 00:00:00 2001 From: Ryu <114303361+ryuapp@users.noreply.github.com> Date: Mon, 9 Mar 2026 03:44:06 +0900 Subject: [PATCH 4/4] fmt --- src/commands/clean.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/commands/clean.rs b/src/commands/clean.rs index 4b91176..e26c393 100644 --- a/src/commands/clean.rs +++ b/src/commands/clean.rs @@ -14,7 +14,11 @@ pub fn run() { Err(e) => panic!("Failed to remove {}: {}", dir, e), } } - eprintln!("Removed {} files, {}", file_count, format_bytes(total_bytes)); + eprintln!( + "Removed {} files, {}", + file_count, + format_bytes(total_bytes) + ); } fn walk_dir_stats(dir: &Path) -> (usize, u64) {