diff --git a/Cargo.lock b/Cargo.lock index b854e8ab804..318c29ba95e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1988,13 +1988,14 @@ dependencies = [ [[package]] name = "parse_datetime" -version = "0.9.0" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd3830b49ee3a0dcc8fdfadc68c6354c97d00101ac1cac5b2eee25d35c42066" +checksum = "c5b77d27257a460cefd73a54448e5f3fd4db224150baf6ca3e02eedf4eb2b3e9" dependencies = [ "chrono", - "nom 8.0.0", + "num-traits", "regex", + "winnow", ] [[package]] @@ -4311,7 +4312,7 @@ version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.59.0", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 49258db5576..b5e01e6b8fe 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -337,7 +337,7 @@ num-prime = "0.4.4" num-traits = "0.2.19" number_prefix = "0.4" onig = { version = "~6.5.1", default-features = false } -parse_datetime = "0.9.0" +parse_datetime = "0.11.0" phf = "0.12.1" phf_codegen = "0.12.1" platform-info = "2.0.3" diff --git a/fuzz/Cargo.lock b/fuzz/Cargo.lock index c69adf67440..47433209536 100644 --- a/fuzz/Cargo.lock +++ b/fuzz/Cargo.lock @@ -993,13 +993,14 @@ dependencies = [ [[package]] name = "parse_datetime" -version = "0.9.0" +version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd3830b49ee3a0dcc8fdfadc68c6354c97d00101ac1cac5b2eee25d35c42066" +checksum = "c5b77d27257a460cefd73a54448e5f3fd4db224150baf6ca3e02eedf4eb2b3e9" dependencies = [ "chrono", - "nom", + "num-traits", "regex", + "winnow", ] [[package]] @@ -1981,6 +1982,15 @@ version = "0.53.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "271414315aff87387382ec3d271b52d7ae78726f5d44ac98b4f4030c91880486" +[[package]] +name = "winnow" +version = "0.7.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3edebf492c8125044983378ecb5766203ad3b4c2f7a922bd7dd207f6d443e95" +dependencies = [ + "memchr", +] + [[package]] name = "wit-bindgen-rt" version = "0.39.0" diff --git a/tests/by-util/test_touch.rs b/tests/by-util/test_touch.rs index 70a809b95ec..6c2d3ff1b67 100644 --- a/tests/by-util/test_touch.rs +++ b/tests/by-util/test_touch.rs @@ -684,7 +684,8 @@ fn test_touch_set_date_relative_smoke() { "2 seconds", "2 years 1 week", "2 days ago", - "2 months and 1 second", + "2 months 1 second", + "a", ]; for time in times { let (at, mut ucmd) = at_and_ucmd!(); @@ -694,11 +695,6 @@ fn test_touch_set_date_relative_smoke() { .no_stderr() .no_stdout(); } - let (at, mut ucmd) = at_and_ucmd!(); - at.touch("f"); - ucmd.args(&["-d", "a", "f"]) - .fails() - .stderr_contains("touch: Unable to parse date"); } #[test]