mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-10 16:45:51 +03:00
Merge pull request #277606 from zshipko/update-extism-cli
extism-cli: 0.1.0 -> 0.3.8
This commit is contained in:
commit
3d54a95d71
@ -20764,6 +20764,12 @@
|
|||||||
githubId = 8100652;
|
githubId = 8100652;
|
||||||
name = "David Mell";
|
name = "David Mell";
|
||||||
};
|
};
|
||||||
|
zshipko = {
|
||||||
|
email = "zachshipko@gmail.com";
|
||||||
|
github = "zshipko";
|
||||||
|
githubId = 332534;
|
||||||
|
name = "Zach Shipko";
|
||||||
|
};
|
||||||
ztzg = {
|
ztzg = {
|
||||||
email = "dd@crosstwine.com";
|
email = "dd@crosstwine.com";
|
||||||
github = "ztzg";
|
github = "ztzg";
|
||||||
|
@ -1,37 +1,43 @@
|
|||||||
{ lib, stdenvNoCC, fetchFromGitHub, python3, makeBinaryWrapper }:
|
{
|
||||||
|
lib
|
||||||
|
, buildGoModule
|
||||||
|
, fetchFromGitHub
|
||||||
|
, installShellFiles
|
||||||
|
}:
|
||||||
|
|
||||||
stdenvNoCC.mkDerivation rec {
|
buildGoModule rec {
|
||||||
pname = "extism-cli";
|
pname = "extism-cli";
|
||||||
version = "0.1.0";
|
version = "0.3.8";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "extism";
|
owner = "extism";
|
||||||
repo = "cli";
|
repo = "cli";
|
||||||
rev = "97935786166e82154266b82410028482800e6061";
|
rev = "refs/tags/v${version}";
|
||||||
sha256 = "sha256-LRzXuZQt5h3exw43UXUwLVIhveYVFw/SQ2YtHI9ZnWc=";
|
hash = "sha256-StMipPMLSQzrhWv0yoKkNiuHMRW7QIhmVZ/M27WDWrM=";
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs = [ python3 ];
|
modRoot = "./extism";
|
||||||
nativeBuildInputs = [ makeBinaryWrapper ];
|
|
||||||
|
|
||||||
installPhase = ''
|
vendorHash = "sha256-sSKiwYT5EP0FQJbhgv9ZFDwwwvIJ66yMULbj529AZwY=";
|
||||||
runHook preInstall
|
|
||||||
|
|
||||||
install -D -m 755 ./extism_cli/__init__.py "$out/bin/extism"
|
nativeBuildInputs = [ installShellFiles ];
|
||||||
|
|
||||||
# The extism cli tries by default to install a library and header into /usr/local which does not work on NixOS.
|
doCheck = false; # Tests require network access
|
||||||
# Pass a reasonable writable directory which can still be overwritten with another --prefix argument.
|
|
||||||
wrapProgram "$out/bin/extism" \
|
|
||||||
--add-flags '--prefix $HOME/.local'
|
|
||||||
|
|
||||||
runHook postInstall
|
postInstall = ''
|
||||||
|
local INSTALL="$out/bin/extism"
|
||||||
|
installShellCompletion --cmd extism \
|
||||||
|
--bash <($out/bin/containerlab completion bash) \
|
||||||
|
--fish <($out/bin/containerlab completion fish) \
|
||||||
|
--zsh <($out/bin/containerlab completion zsh)
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "The extism CLI is used to manage Extism installations";
|
description = "The extism CLI is used to manage Extism installations";
|
||||||
homepage = "https://github.com/extism/cli";
|
homepage = "https://github.com/extism/cli";
|
||||||
license = licenses.bsd3;
|
license = licenses.bsd3;
|
||||||
maintainers = with maintainers; [ ];
|
maintainers = with maintainers; [ zshipko ];
|
||||||
|
mainProgram = "extism";
|
||||||
platforms = platforms.all;
|
platforms = platforms.all;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user