From d5bf8e7f685c72131fe10793019317a93fd3b9d9 Mon Sep 17 00:00:00 2001 From: Fintan Halpenny Date: Mon, 4 Mar 2024 17:34:36 +0000 Subject: [PATCH] nix: update to rust-1.76 Run `niv update` to get the latest Rust toolchain. This required applying some clippy improvements: - Removing unnecessary re-export of Oid in `stats` module. - Replace `get(0)` with `first` Signed-off-by: Fintan Halpenny X-Clacks-Overhead: GNU Terry Pratchett --- nix/sources.json | 12 ++++++------ radicle-surf/src/stats.rs | 2 -- radicle-surf/t/src/diff.rs | 2 +- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/nix/sources.json b/nix/sources.json index 8e21c1c..afe4aaa 100644 --- a/nix/sources.json +++ b/nix/sources.json @@ -5,10 +5,10 @@ "homepage": "https://github.com/nmattia/niv", "owner": "nmattia", "repo": "niv", - "rev": "723f0eeb969a730db3c30f977c2b66b9dce9fe4a", - "sha256": "0016l7230gd2kdh0g2w573r9a2krqb7x4ifcjhhsn4h1bwap7qr0", + "rev": "d67c25f29716fd2087e71352783fcce194303a9a", + "sha256": "1813r42sz4pmv1syn38s281lmg2l7h779q4r33nn5azm7wy45yrh", "type": "tarball", - "url": "https://github.com/nmattia/niv/archive/723f0eeb969a730db3c30f977c2b66b9dce9fe4a.tar.gz", + "url": "https://github.com/nmattia/niv/archive/d67c25f29716fd2087e71352783fcce194303a9a.tar.gz", "url_template": "https://github.com///archive/.tar.gz" }, "nixpkgs": { @@ -29,10 +29,10 @@ "homepage": "", "owner": "oxalica", "repo": "rust-overlay", - "rev": "7c94410d52d4e8bd72803fc1fe6c51fe179edaf5", - "sha256": "1m4awxwvmwmv61fpl9jwfg2ka241hwl37rqffw6lpqb8rj3safff", + "rev": "e86c0fb5d3a22a5f30d7f64ecad88643fe26449d", + "sha256": "138pmz1ypw5j34bywfaffxkffsgfmd0s6889bdc69356cp11zvlm", "type": "tarball", - "url": "https://github.com/oxalica/rust-overlay/archive/7c94410d52d4e8bd72803fc1fe6c51fe179edaf5.tar.gz", + "url": "https://github.com/oxalica/rust-overlay/archive/e86c0fb5d3a22a5f30d7f64ecad88643fe26449d.tar.gz", "url_template": "https://github.com///archive/.tar.gz" } } diff --git a/radicle-surf/src/stats.rs b/radicle-surf/src/stats.rs index f9dd7e1..312ca8e 100644 --- a/radicle-surf/src/stats.rs +++ b/radicle-surf/src/stats.rs @@ -15,8 +15,6 @@ // You should have received a copy of the GNU General Public License // along with this program. If not, see . -pub use radicle_git_ext::Oid; - #[cfg(feature = "serde")] use serde::Serialize; diff --git a/radicle-surf/t/src/diff.rs b/radicle-surf/t/src/diff.rs index a52fc95..2de12a6 100644 --- a/radicle-surf/t/src/diff.rs +++ b/radicle-surf/t/src/diff.rs @@ -129,7 +129,7 @@ fn test_diff() -> Result<(), Error> { let repo = Repository::open(GIT_PLATINUM)?; let oid = "80bacafba303bf0cdf6142921f430ff265f25095"; let commit = repo.commit(oid).unwrap(); - let parent_oid = commit.parents.get(0).unwrap(); + let parent_oid = commit.parents.first().unwrap(); let diff = repo.diff(*parent_oid, oid)?; let expected_files = vec![FileDiff::Modified(Modified {