mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
libcpucycles: add update script (#339585)
This commit is contained in:
commit
6cda5aebc8
@ -31,6 +31,8 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
install_name_tool -change "libcpucycles.1.dylib" "$out/lib/libcpucycles.1.dylib" "$out/bin/cpucycles-info"
|
||||
'';
|
||||
|
||||
passthru.updateScript = ./update.sh;
|
||||
|
||||
meta = {
|
||||
homepage = "https://cpucycles.cr.yp.to/";
|
||||
description = "Microlibrary for counting CPU cycles";
|
||||
|
11
pkgs/by-name/li/libcpucycles/update.sh
Executable file
11
pkgs/by-name/li/libcpucycles/update.sh
Executable file
@ -0,0 +1,11 @@
|
||||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i bash -p curl cacert nix common-updater-scripts --pure
|
||||
#shellcheck shell=bash
|
||||
|
||||
set -eu -o pipefail
|
||||
|
||||
# upstream doesn't use git, but has this file specifically for versioning
|
||||
version="$(curl https://cpucycles.cr.yp.to/libcpucycles-latest-version.txt)"
|
||||
|
||||
update-source-version libcpucycles "$version"
|
||||
|
Loading…
Reference in New Issue
Block a user