blob: ea3fc3bfa5fc7c62e73e33954420438d500f1643 (
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
|
{ lib
, stdenv
, buildNpmPackage
, fetchFromGitHub
, pkg-config
, libsecret
, darwin
, python3
, testers
, vsce
}:
buildNpmPackage rec {
pname = "vsce";
version = "2.25.0";
src = fetchFromGitHub {
owner = "microsoft";
repo = "vscode-vsce";
rev = "v${version}";
hash = "sha256-HPNKxplSJpo/30vpXu176JMzY3fAzTX/9XPRsYj9x+U=";
};
npmDepsHash = "sha256-wfgvGWSxV+N9Uh+jEEZCwPEN0yYNmooWXAV9PwWONkM=";
postPatch = ''
substituteInPlace package.json --replace '"version": "0.0.0"' '"version": "${version}"'
'';
nativeBuildInputs = [ pkg-config python3 ];
buildInputs = [ libsecret ]
++ lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [ AppKit Security ]);
makeCacheWritable = true;
npmFlags = [ "--legacy-peer-deps" ];
passthru.tests.version = testers.testVersion {
package = vsce;
};
meta = with lib; {
homepage = "https://github.com/microsoft/vscode-vsce";
description = "Visual Studio Code Extension Manager";
maintainers = with maintainers; [ aaronjheng ];
license = licenses.mit;
mainProgram = "vsce";
};
}
|