emacs.pkgs.tsc: Remove with from top-level scope

This is a huge anti-pattern that makes it next to impossible to know
which attrset is providing which attr and it's very easy to make mistakes.

Case in point: This package didn't properly scope `lib.maintainers`.
This commit is contained in:
adisbladis 2022-04-23 22:46:58 +12:00
parent 48b6b19970
commit 4567405cd4

View File

@ -7,9 +7,6 @@
, clang
, llvmPackages
}:
with lib.licenses;
with rustPlatform;
with llvmPackages;
let
version = "0.16.1";
@ -37,7 +34,7 @@ let
'';
};
tsc-dyn = buildRustPackage {
tsc-dyn = rustPlatform.buildRustPackage {
inherit version;
inherit src;
@ -47,7 +44,7 @@ let
sourceRoot = "source/core";
configurePhase = ''
export LIBCLANG_PATH="${libclang.lib}/lib"
export LIBCLANG_PATH="${llvmPackages.libclang.lib}/lib"
'';
postInstall = ''
@ -61,13 +58,14 @@ let
cargoSha256 = "sha256-7UOhs3wx6fGvqPjNxUKoEHwPtiJ5zgLFPwDSvhYlmis=";
};
in symlinkJoin {
name = "tsc";
name = "tsc-${version}";
paths = [ tsc tsc-dyn ];
meta = {
description = "The core APIs of the Emacs binding for tree-sitter.";
license = mit;
maintainers = with maintainers; [ pimeys ];
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ pimeys ];
};
}