nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 stdenv,
4 buildNpmPackage,
5 fetchFromGitHub,
6 nodejs_22,
7 cacert,
8}:
9
10buildNpmPackage rec {
11 pname = "inshellisense";
12 version = "0.0.1-rc.21";
13
14 src = fetchFromGitHub {
15 owner = "microsoft";
16 repo = "inshellisense";
17 tag = version;
18 hash = "sha256-zERwrvioPwGm/351kYuK9S3uOrrzs/6OFPRdNSSr7Tc=";
19 };
20
21 # Building against nodejs-24 is not yet supported by upstream.
22 # https://github.com/microsoft/inshellisense/issues/369
23 nodejs = nodejs_22;
24
25 npmDepsHash = "sha256-iD5SvkVbrHh0Hx44y6VtNerwBA8K7vSe/yfvhgndMEw=";
26
27 # Needed for dependency `@homebridge/node-pty-prebuilt-multiarch`
28 # On Darwin systems the build fails with,
29 #
30 # npm ERR! ../src/unix/pty.cc:413:13: error: use of undeclared identifier 'openpty'
31 # npm ERR! int ret = openpty(&master, &slave, nullptr, NULL, static_cast<winsi ze*>(&winp));
32 #
33 # when `node-gyp` tries to build the dep. The below allows `npm` to download the prebuilt binary.
34 makeCacheWritable = stdenv.hostPlatform.isDarwin;
35 nativeBuildInputs = lib.optional stdenv.hostPlatform.isDarwin cacert;
36
37 meta = {
38 description = "IDE style command line auto complete";
39 homepage = "https://github.com/microsoft/inshellisense";
40 license = lib.licenses.mit;
41 maintainers = [ lib.maintainers.malo ];
42 };
43}