Skip to content

Commit 14781fc

Browse files
authored
luau-lsp: init at 1.45.0 (#395892)
2 parents 3429849 + 5f15206 commit 14781fc

File tree

3 files changed

+78
-3
lines changed

3 files changed

+78
-3
lines changed

maintainers/maintainer-list.nix

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1703,6 +1703,11 @@
17031703
githubId = 81317317;
17041704
name = "Anna Aurora";
17051705
};
1706+
anninzy = {
1707+
github = "anninzy";
1708+
githubId = 143312793;
1709+
name = "Annin";
1710+
};
17061711
anoa = {
17071712
matrix = "@andrewm:amorgan.xyz";
17081713
email = "[email protected]";

pkgs/applications/editors/vim/plugins/overrides.nix

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,8 @@
118118
# typst-preview dependencies
119119
tinymist,
120120
websocat,
121+
# luau-lsp-nvim dependencies
122+
luau-lsp,
121123
}:
122124
self: super:
123125
let
@@ -1690,9 +1692,7 @@ in
16901692

16911693
luau-lsp-nvim = super.luau-lsp-nvim.overrideAttrs {
16921694
dependencies = [ self.plenary-nvim ];
1693-
1694-
# TODO: add luau-lsp to nixpkgs (#395892)
1695-
# runtimeDeps = [ luau-lsp ];
1695+
runtimeDeps = [ luau-lsp ];
16961696
};
16971697

16981698
magma-nvim = super.magma-nvim.overrideAttrs {
Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
{
2+
lib,
3+
stdenv,
4+
fetchFromGitHub,
5+
cmake,
6+
versionCheckHook,
7+
nix-update-script,
8+
}:
9+
10+
stdenv.mkDerivation (finalAttrs: {
11+
pname = "luau-lsp";
12+
version = "1.45.0";
13+
14+
src = fetchFromGitHub {
15+
owner = "JohnnyMorganz";
16+
repo = "luau-lsp";
17+
tag = finalAttrs.version;
18+
hash = "sha256-OJAjTy0vTRb43TTiPeXafWq4kjIpnDXoTprVzbMnaWQ=";
19+
fetchSubmodules = true;
20+
};
21+
22+
NIX_CFLAGS_COMPILE = "-Wno-error";
23+
24+
cmakeFlags = lib.optionals stdenv.hostPlatform.isDarwin [
25+
(lib.cmakeFeature "CMAKE_OSX_ARCHITECTURES" stdenv.hostPlatform.darwinArch)
26+
];
27+
28+
nativeBuildInputs = [ cmake ];
29+
30+
buildPhase = ''
31+
runHook preBuild
32+
33+
cmake --build . --target Luau.LanguageServer.CLI --config Release
34+
35+
runHook postBuild
36+
'';
37+
38+
installPhase = ''
39+
runHook preInstall
40+
41+
install -D luau-lsp $out/bin/luau-lsp
42+
43+
runHook postInstall
44+
'';
45+
46+
nativeInstallCheckInputs = [ versionCheckHook ];
47+
versionCheckProgramArg = "--version";
48+
doInstallCheck = true;
49+
50+
passthru.updateScript = nix-update-script { };
51+
52+
meta = {
53+
description = "Language Server Implementation for Luau";
54+
homepage = "https://github.com/JohnnyMorganz/luau-lsp";
55+
downloadPage = "https://github.com/JohnnyMorganz/luau-lsp/releases/tag/${finalAttrs.version}";
56+
changelog = "https://github.com/JohnnyMorganz/luau-lsp/blob/${finalAttrs.version}/CHANGELOG.md";
57+
license = lib.licenses.mit;
58+
maintainers = with lib.maintainers; [
59+
anninzy
60+
HeitorAugustoLN
61+
];
62+
mainProgram = "luau-lsp";
63+
platforms = lib.platforms.all;
64+
badPlatforms = [
65+
# Could not find a package configuration file provided by "Protobuf"
66+
# It is unclear why this is only happening on x86_64-darwin
67+
"x86_64-darwin"
68+
];
69+
};
70+
})

0 commit comments

Comments
 (0)