blob: 1036022bc68b83355071d7122343bfa9ea6fbf71 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
{ buildGoModule
, fetchFromGitHub
, lib
, nix-update-script
, testers
, symfony-cli
, nssTools
, makeBinaryWrapper
}:
buildGoModule rec {
pname = "symfony-cli";
version = "5.8.16";
vendorHash = "sha256-bhlD7EgOkWjRTsw1hH0GKjtFkLbOzr28wR4JJKOJwnY=";
src = fetchFromGitHub {
owner = "symfony-cli";
repo = "symfony-cli";
rev = "v${version}";
hash = "sha256-V67RLa/Tn9ZdV+vnhFSht0wtIYYZOAGAYP9R1Lxn9aI=";
};
ldflags = [
"-s"
"-w"
"-X main.version=${version}"
"-X main.channel=stable"
];
buildInputs = [ makeBinaryWrapper ];
postInstall = ''
mkdir $out/libexec
mv $out/bin/symfony-cli $out/libexec/symfony
makeBinaryWrapper $out/libexec/symfony $out/bin/symfony \
--prefix PATH : ${lib.makeBinPath [ nssTools ]}
'';
# Tests requires network access
doCheck = false;
passthru = {
updateScript = nix-update-script { };
tests.version = testers.testVersion {
inherit version;
package = symfony-cli;
command = "symfony version --no-ansi";
};
};
meta = {
changelog = "https://github.com/symfony-cli/symfony-cli/releases/tag/v${version}";
description = "Symfony CLI";
homepage = "https://github.com/symfony-cli/symfony-cli";
license = lib.licenses.agpl3Plus;
mainProgram = "symfony";
maintainers = with lib.maintainers; [ drupol ];
};
}
|