2023-11-25 04:20:00 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
stdenvNoCC,
|
|
|
|
nodejs-slim,
|
|
|
|
fetchzip,
|
|
|
|
testers,
|
|
|
|
}:
|
2023-01-03 04:20:00 +00:00
|
|
|
|
|
|
|
stdenvNoCC.mkDerivation (finalAttrs: {
|
|
|
|
pname = "twilio-cli";
|
2024-11-26 19:28:17 +00:00
|
|
|
version = "5.22.6";
|
2023-01-03 04:20:00 +00:00
|
|
|
|
|
|
|
src = fetchzip {
|
|
|
|
url = "https://twilio-cli-prod.s3.amazonaws.com/twilio-v${finalAttrs.version}/twilio-v${finalAttrs.version}.tar.gz";
|
2024-11-26 19:28:17 +00:00
|
|
|
hash = "sha256-2t/KtUoDRgDJtA/kN31hTZN0CWOVyX4/BXYZGTl9CdY=";
|
2023-01-03 04:20:00 +00:00
|
|
|
};
|
|
|
|
|
2023-11-25 04:20:00 +00:00
|
|
|
buildInputs = [ nodejs-slim ];
|
2023-01-03 04:20:00 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
mkdir -p $out/bin $out/libexec/twilio-cli
|
|
|
|
cp -R . $out/libexec/twilio-cli
|
|
|
|
ln -s $out/libexec/twilio-cli/bin/run $out/bin/twilio
|
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
|
2023-03-25 04:20:00 +00:00
|
|
|
passthru.tests.version = testers.testVersion {
|
2023-01-03 04:20:00 +00:00
|
|
|
package = finalAttrs.finalPackage;
|
|
|
|
};
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Unleash the power of Twilio from your command prompt";
|
|
|
|
homepage = "https://github.com/twilio/twilio-cli";
|
2023-03-25 04:20:00 +00:00
|
|
|
changelog = "https://github.com/twilio/twilio-cli/blob/${finalAttrs.version}/CHANGES.md";
|
2023-01-03 04:20:00 +00:00
|
|
|
license = licenses.mit;
|
2024-07-28 14:44:11 +00:00
|
|
|
maintainers = [ ];
|
2023-11-25 04:20:00 +00:00
|
|
|
platforms = nodejs-slim.meta.platforms;
|
2023-01-03 04:20:00 +00:00
|
|
|
mainProgram = "twilio";
|
|
|
|
};
|
|
|
|
})
|