Skip to content

Commit

Permalink
Use inline format args
Browse files Browse the repository at this point in the history
  • Loading branch information
zargony committed Aug 10, 2024
1 parent 269723f commit 171e71c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion firmware/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ fn main() -> Result<(), Box<dyn Error>> {
let statuses = repo.statuses(Some(&mut status_options))?;
let dirty = statuses.iter().any(|st| !st.status().is_ignored());
let dirty_str = if dirty { "+" } else { "" };
println!("cargo::rustc-env=GIT_SHORT_SHA={}{}", short_sha, dirty_str);
println!("cargo::rustc-env=GIT_SHORT_SHA={short_sha}{dirty_str}");

println!("cargo::rerun-if-changed=build.rs");
println!("cargo::rerun-if-changed=.git/");
Expand Down
2 changes: 1 addition & 1 deletion firmware/src/keypad.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ where
{
/// Create matrix keypad from given input columns and output rows
pub fn new(cols: [IN; COLS], rows: [OUT; ROWS]) -> Self {
info!("Keypad: {}x{} matrix initialized", ROWS, COLS);
info!("Keypad: {ROWS}x{COLS} matrix initialized");

Self { cols, rows }
}
Expand Down
2 changes: 1 addition & 1 deletion firmware/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ async fn main(_spawner: Spawner) {

// Initialize logging
esp_println::logger::init_logger_from_env();
info!("Touch 'n Drink {} ({})", VERSION_STR, GIT_SHA_STR);
info!("Touch 'n Drink {VERSION_STR} ({GIT_SHA_STR})");

// Initialize I2C controller
let i2c = I2C::new(
Expand Down

0 comments on commit 171e71c

Please sign in to comment.