1 { lib, stdenv, fetchFromGitHub, fetchYarnDeps, yarnConfigHook, yarnInstallHook, nodejs, testers }:
3 stdenv.mkDerivation (finalAttrs: {
7 src = fetchFromGitHub {
8 owner = "codefresh-io";
10 rev = "v${finalAttrs.version}";
11 hash = "sha256-SUwt0oWls823EeLxT4CW+LDdsjAtSxxxKkllhMJXCtM=";
14 offlineCache = fetchYarnDeps {
15 yarnLock = "${finalAttrs.src}/yarn.lock";
16 hash = "sha256-tzsHbvoQ59MwE4TYdPweLaAv9r4V8oyTQyvdeyPCsHY=";
24 passthru.tests.version = testers.testVersion {
25 package = finalAttrs.finalPackage;
26 # codefresh needs to read a config file, this is faked out with a subshell
27 command = "codefresh --cfconfig <(echo 'contexts:') version";
31 changelog = "https://github.com/codefresh-io/cli/releases/tag/v${finalAttrs.version}";
32 description = "Codefresh CLI tool to interact with Codefresh services";
33 homepage = "https://github.com/codefresh-io/cli";
34 license = lib.licenses.mit;
35 mainProgram = "codefresh";
36 maintainers = [ lib.maintainers.takac ];