sourcehut: fix update script

This commit is contained in:
Julien Moutinho 2022-06-02 13:35:20 +02:00 committed by tomberek
parent a097ca163e
commit 5da4b29a99
2 changed files with 6 additions and 4 deletions

View file

@ -1,5 +1,5 @@
{ lib
, fetchhg
, fetchFromSourcehut
, buildGoModule
, buildPythonPackage
, srht
@ -14,10 +14,12 @@ buildPythonPackage rec {
pname = "hgsrht";
version = "0.31.2";
src = fetchhg {
url = "https://hg.sr.ht/~sircmpwn/hg.sr.ht";
src = fetchFromSourcehut {
owner = "~sircmpwn";
repo = "hg.sr.ht";
rev = version;
sha256 = "F0dBykSSrlis+mumULLxvKNxD75DWR9+IDTYbmhkMDI=";
vc = "hg";
};
postPatch = ''
substituteInPlace Makefile \

View file

@ -16,7 +16,7 @@ version() {
}
src_url() {
nix-instantiate --eval --strict --expr " with import $root {}; let src = sourcehut.python.pkgs.$1.drvAttrs.src; in src.url or src.meta.homepage" | tr -d '"'
nix-instantiate --eval --strict --expr " with import $root {}; let src = sourcehut.python.pkgs.$1.drvAttrs.src; in src.meta.homepage" | tr -d '"'
}
get_latest_version() {