From 4094dacee822448a1f9ab6e733f1d2da32f13115 Mon Sep 17 00:00:00 2001 From: Alpha Chen Date: Fri, 24 Apr 2026 14:35:34 +0000 Subject: [PATCH] Add project AGENTS.md and remove unused miette import Assisted-by: GLM-5.1 via pi --- AGENTS.md | 12 ++++++++++++ src/bin/quire/commands/exec.rs | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 AGENTS.md diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..9a722e5 --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,12 @@ +# Project conventions + +## Before committing + +Always run `cargo test` and verify all tests pass before committing. +Never skip this step, even for small or "obvious" changes. + +## Rust conventions + +- Use `fs_err` instead of `std::fs` (enforced by clippy) +- Use miette's `bail!` and `ensure!` macros instead of `return Err(miette!(...))` +- Prefer `for` loops over `Iterator::for_each` for side-effects (enforced by clippy) diff --git a/src/bin/quire/commands/exec.rs b/src/bin/quire/commands/exec.rs index 780eb5c..85ad17c 100644 --- a/src/bin/quire/commands/exec.rs +++ b/src/bin/quire/commands/exec.rs @@ -1,7 +1,7 @@ use std::os::unix::process::CommandExt; use std::process::Command; -use miette::{Context, IntoDiagnostic, Result, miette, bail, ensure}; +use miette::{Context, IntoDiagnostic, Result, bail, ensure}; use quire::Config; -- 2.54.0