forked from mirrors/nixpkgs
Merge pull request #146325 from ryantm/dev/ryantm/discourse-update-py
discourse/update.py: fix for nix 2.4/2.5pre
This commit is contained in:
commit
7dfea71857
|
@ -79,7 +79,7 @@ def _call_nix_update(pkg, version):
|
|||
def _nix_eval(expr: str):
|
||||
nixpkgs_path = Path(__file__).parent / '../../../../'
|
||||
try:
|
||||
output = subprocess.check_output(['nix', 'eval', '--json', f'(with import {nixpkgs_path} {{}}; {expr})'], text=True)
|
||||
output = subprocess.check_output(['nix-instantiate', '--strict', '--json', '--eval', '-E', f'(with import {nixpkgs_path} {{}}; {expr})'], text=True)
|
||||
except subprocess.CalledProcessError:
|
||||
return None
|
||||
return json.loads(output)
|
||||
|
|
|
@ -6,13 +6,13 @@
|
|||
# No gems used, so mkDerivation is fine.
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "nix-universal-prefetch";
|
||||
version = "0.3.0";
|
||||
version = "0.4.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "samueldr";
|
||||
repo = "nix-universal-prefetch";
|
||||
rev = "v${version}";
|
||||
sha256 = "1nmxp6846ip2x3mibys3ymgi0813g18p9szqnsciiib3dbis4kwf";
|
||||
sha256 = "sha256-HGn4qHWqpUwlS3yQrD3j5oH0yOlphsoSPD2vkyyRv+0=";
|
||||
};
|
||||
|
||||
installPhase = ''
|
||||
|
|
Loading…
Reference in a new issue