From fd0cbc696a6cf96ec8d0de7f67e44d51debf782e Mon Sep 17 00:00:00 2001 From: Felix Buehler Date: Sun, 19 Sep 2021 19:08:58 +0200 Subject: [PATCH] bcache-tools: switch to fetchFromGitHub --- pkgs/tools/filesystems/bcache-tools/default.nix | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/pkgs/tools/filesystems/bcache-tools/default.nix b/pkgs/tools/filesystems/bcache-tools/default.nix index ba6cb79fbd57..f6dfdd84d8c4 100644 --- a/pkgs/tools/filesystems/bcache-tools/default.nix +++ b/pkgs/tools/filesystems/bcache-tools/default.nix @@ -1,13 +1,14 @@ -{ lib, stdenv, fetchurl, pkg-config, util-linux, bash }: +{ lib, stdenv, fetchFromGitHub, pkg-config, util-linux, bash }: stdenv.mkDerivation rec { pname = "bcache-tools"; version = "1.0.7"; - src = fetchurl { - name = "${pname}-${version}.tar.gz"; - url = "https://github.com/g2p/bcache-tools/archive/v${version}.tar.gz"; - sha256 = "1gbsh2qw0a7kgck6w0apydiy37nnz5xvdgipa0yqrfmghl86vmv4"; + src = fetchFromGitHub { + owner = "g2p"; + repo = "bcache-tools"; + rev = "v${version}"; + hash = "sha256-Ors2xXRrVTf8Cq3BYnSVSfJy/nyGjT5BGLSNpxOcHR4="; }; nativeBuildInputs = [ pkg-config ];