depot/third_party/nixpkgs/pkgs/development/tools/language-servers/helm-ls/default.nix
Default email 5c370c0b2a Project import generated by Copybara.
GitOrigin-RevId: 33d1e753c82ffc557b4a585c77de43d4c922ebb5
2024-05-15 17:35:15 +02:00

51 lines
1.2 KiB
Nix

{ lib
, buildGoModule
, fetchFromGitHub
, installShellFiles
, testers
, helm-ls
}:
buildGoModule rec {
pname = "helm-ls";
version = "0.0.16";
src = fetchFromGitHub {
owner = "mrjosh";
repo = "helm-ls";
rev = "v${version}";
hash = "sha256-y4FYcago8tVK4ru6tLizEgOLsMuryFmJUa2D8fXulDg=";
};
vendorHash = "sha256-ZeJeLpuac8ecKCOv2gXpT/P4GBFstB6lUaKOhQKFRAE=";
nativeBuildInputs = [ installShellFiles ];
ldflags = [
"-s"
"-w"
"-X main.Version=${version}"
];
postInstall = ''
mv $out/bin/helm-ls $out/bin/helm_ls
installShellCompletion --cmd helm_ls \
--bash <($out/bin/helm_ls completion bash) \
--fish <($out/bin/helm_ls completion fish) \
--zsh <($out/bin/helm_ls completion zsh)
'';
passthru.tests.version = testers.testVersion {
package = helm-ls;
command = "helm_ls version";
};
meta = with lib; {
description = "Language server for Helm";
changelog = "https://github.com/mrjosh/helm-ls/releases/tag/v${version}";
homepage = "https://github.com/mrjosh/helm-ls";
license = licenses.mit;
maintainers = with maintainers; [ stehessel ];
mainProgram = "helm_ls";
};
}