diff options
Diffstat (limited to 'pkgs/by-name/ty/typos-lsp/package.nix')
-rw-r--r-- | pkgs/by-name/ty/typos-lsp/package.nix | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/pkgs/by-name/ty/typos-lsp/package.nix b/pkgs/by-name/ty/typos-lsp/package.nix new file mode 100644 index 0000000000000..0c69a0cf1a4ce --- /dev/null +++ b/pkgs/by-name/ty/typos-lsp/package.nix @@ -0,0 +1,34 @@ +{ lib +, rustPlatform +, fetchFromGitHub +}: +rustPlatform.buildRustPackage rec { + pname = "typos-lsp"; + # Please update the corresponding VSCode extension too. + # See pkgs/applications/editors/vscode/extensions/tekumara.typos-vscode/default.nix + version = "0.1.18"; + + src = fetchFromGitHub { + owner = "tekumara"; + repo = "typos-lsp"; + rev = "refs/tags/v${version}"; + hash = "sha256-6ELn2Q7pAUgnwe8+vAUbuRjaKFWvbGZ1SMfXQ1qKp5c="; + }; + + cargoHash = "sha256-UDID+dI8ETP084WR482uWli2++bI4mRiMvpFpWUlvZE="; + + # fix for compilation on aarch64 + # see https://github.com/NixOS/nixpkgs/issues/145726 + prePatch = '' + rm .cargo/config.toml + ''; + + meta = with lib; { + description = "Source code spell checker"; + homepage = "https://github.com/tekumara/typos-lsp"; + changelog = "https://github.com/tekumara/typos-lsp/blob/${src.rev}/CHANGELOG.md"; + license = licenses.mit; + maintainers = with maintainers; [ tarantoj ]; + mainProgram = "typos-lsp"; + }; +} |