Skip to content

Commit 39c2917

Browse files
committed
bump to 1.5.2 capitalize schedule times
1 parent c579181 commit 39c2917

File tree

6 files changed

+32
-8
lines changed

6 files changed

+32
-8
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1010
### Fixed
1111
- Ensured macOS bundles include the app icon by bundling from the mac crate (restores Finder/Launchpad icon rendering).
1212

13+
## [1.5.2] - 2025-11-30
14+
15+
### Changed
16+
- Capitalized scheduled task time strings (“Next run”/“Last run”) for clearer menu display.
17+
1318
## [1.5.0] - 2025-11-30
1419

1520
### Changed

Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ members = ["core", "app-macos", "app-linux", "app-windows"]
33
resolver = "2"
44

55
[workspace.package]
6-
version = "1.5.1"
6+
version = "1.5.2"
77
edition = "2024"
88

99
[profile.release]

RELEASE_NOTES.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,14 @@
88

99
- Bundling now runs from the macOS crate so the `circle.icns` app icon is included again; Finder/Launchpad show the proper icon.
1010

11+
## v1.5.2
12+
13+
**Release Date:** November 30, 2025
14+
15+
### 🔠 Menu Polish
16+
17+
- “Next run” and “Last run” entries now start with capitalized relative time text for better readability in the scheduled task submenus.
18+
1119
## v1.5.0
1220

1321
**Release Date:** November 30, 2025

core/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "something_bg_core"
3-
version = "1.5.1"
3+
version = "1.5.2"
44
edition = "2024"
55

66
[dependencies]

core/src/scheduler.rs

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -525,7 +525,7 @@ fn format_relative_datetime(dt: &DateTime<Local>) -> String {
525525
let diff_days = date_diff.num_days();
526526
let time_part = dt.format("%H:%M").to_string();
527527

528-
match diff_days {
528+
let phrase = match diff_days {
529529
0 => format!("today at {time_part}"),
530530
1 => format!("tomorrow at {time_part}"),
531531
-1 => format!("yesterday at {time_part}"),
@@ -541,7 +541,9 @@ fn format_relative_datetime(dt: &DateTime<Local>) -> String {
541541
let relative = humantime_fmt::format_relative((*dt).into());
542542
format!("{relative} (on {date_str} at {time_part})")
543543
}
544-
}
544+
};
545+
546+
capitalize_first(&phrase)
545547
}
546548

547549
/// Return ordinal suffix for a day (1st, 2nd, 3rd, 4th, ...).
@@ -558,3 +560,12 @@ fn ordinal(day: u32) -> String {
558560

559561
format!("{day}{suffix}")
560562
}
563+
564+
/// Capitalize the first ASCII letter, leaving the rest unchanged.
565+
fn capitalize_first(s: &str) -> String {
566+
let mut chars = s.chars();
567+
match chars.next() {
568+
Some(first) => first.to_uppercase().collect::<String>() + chars.as_str(),
569+
None => String::new(),
570+
}
571+
}

0 commit comments

Comments
 (0)