mpls: init at 0.12.0

This commit is contained in:
jervw
2025-02-18 16:16:21 +02:00
parent da2d3e462f
commit 96c93afd61
+42
View File
@@ -0,0 +1,42 @@
{
lib,
buildGoModule,
fetchFromGitHub,
nix-update-script,
versionCheckHook,
}:
buildGoModule rec {
pname = "mpls";
version = "0.12.0";
src = fetchFromGitHub {
owner = "mhersson";
repo = "mpls";
tag = "v${version}";
hash = "sha256-2NOP5k3N2T2T8zg/6SlKDRJsWt+LcjAOmYe/tMrjCnc=";
};
vendorHash = "sha256-6iXZWLCF0LfchcGSFrCtILLeR1Yx7oxD/7JIYyrrkHM=";
ldflags = [
"-s"
"-w"
"-X github.com/mhersson/mpls/cmd.Version=${version}"
"-X github.com/mhersson/mpls/internal/mpls.Version=${version}"
];
nativeInstallCheckInputs = [ versionCheckHook ];
versionCheckProgramArg = "--version";
doInstallCheck = true;
passthru.updateScript = nix-update-script { };
meta = {
description = "Live preview of markdown using Language Server Protocol";
homepage = "https://github.com/mhersson/mpls";
changelog = "https://github.com/mhersson/mpls/releases/tag/${src.tag}";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ jervw ];
mainProgram = "mpls";
};
}