mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 14:54:29 +01:00
rocm-smi: add update script and fix url
This commit is contained in:
parent
4e89f2a609
commit
52e1574f25
1 changed files with 9 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake, wrapPython }:
|
||||
{ lib, stdenv, fetchFromGitHub, writeScript, cmake, wrapPython }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "rocm-smi";
|
||||
|
@ -42,9 +42,16 @@ stdenv.mkDerivation rec {
|
|||
wrapPythonProgramsIn $out/bin
|
||||
'';
|
||||
|
||||
passthru.updateScript = writeScript "update.sh" ''
|
||||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i bash -p curl jq common-updater-scripts
|
||||
version="$(curl -sL "https://api.github.com/repos/RadeonOpenCompute/rocm_smi_lib/releases?per_page=1" | jq '.[0].tag_name | split("-") | .[1]' --raw-output)"
|
||||
update-source-version rocm-smi "$version"
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "System management interface for AMD GPUs supported by ROCm";
|
||||
homepage = "https://github.com/RadeonOpenCompute/ROC-smi";
|
||||
homepage = "https://github.com/RadeonOpenCompute/rocm_smi_lib";
|
||||
license = with licenses; [ mit ];
|
||||
maintainers = with maintainers; [ lovesegfault ];
|
||||
platforms = [ "x86_64-linux" ];
|
||||
|
|
Loading…
Reference in a new issue