Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions pkgs/by-name/ri/rime-ls/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
{
lib,
rustPlatform,
fetchFromGitHub,
librime,
rime-data,
}:
rustPlatform.buildRustPackage rec {
pname = "rime-ls";
version = "0.4.0";

src = fetchFromGitHub {
owner = "wlh320";
repo = "rime-ls";
rev = "v${version}";
hash = "sha256-ZqoRFIF3ehfEeTN+ZU+/PAzA4JyS1403+sqZdzwJHA8=";
};

useFetchCargoVendor = true;
cargoHash = "sha256-mbkxOYlOCpNzxVWwG8n4vD8klHGVjvMA8XSsBbifjoM=";

nativeBuildInputs = [ rustPlatform.bindgenHook ];

buildInputs = [ librime ];

# Set RIME_DATA_DIR to work around test_get_candidates during checkPhase
env.RIME_DATA_DIR = "${rime-data}/share/rime-data";

meta = {
description = "Language server for Rime input method engine";
homepage = "https://github.com/wlh320/rime-ls";
license = lib.licenses.bsd3;
platforms = lib.platforms.linux;
maintainers = with lib.maintainers; [ definfo ];
mainProgram = "rime_ls";
};
}