From 1e079ca5ce554a8d54e5ef714f4d06870c47f627 Mon Sep 17 00:00:00 2001 From: Jian Lin <75130626+jian-lin@users.noreply.github.com> Date: Sun, 24 Jul 2022 23:40:27 +0800 Subject: [PATCH] kanata: init at 1.0.5 (#182358) Co-authored-by: Azat Bahawi Co-authored-by: Sandro --- maintainers/maintainer-list.nix | 10 ++++++++ pkgs/tools/system/kanata/default.nix | 35 ++++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ 3 files changed, 47 insertions(+) create mode 100644 pkgs/tools/system/kanata/default.nix diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix index 0cd85c5f6c31..aa0fb9d1e22d 100644 --- a/maintainers/maintainer-list.nix +++ b/maintainers/maintainer-list.nix @@ -7437,6 +7437,16 @@ githubId = 667272; name = "Lincoln Lee"; }; + linj = { + name = "Lin Jian"; + email = "me@linj.tech"; + matrix = "@me:linj.tech"; + github = "jian-lin"; + githubId = 75130626; + keys = [{ + fingerprint = "80EE AAD8 43F9 3097 24B5 3D7E 27E9 7B91 E63A 7FF8"; + }]; + }; linquize = { email = "linquize@yahoo.com.hk"; github = "linquize"; diff --git a/pkgs/tools/system/kanata/default.nix b/pkgs/tools/system/kanata/default.nix new file mode 100644 index 000000000000..e3a377163e3e --- /dev/null +++ b/pkgs/tools/system/kanata/default.nix @@ -0,0 +1,35 @@ +{ fetchFromGitHub +, lib +, libevdev +, pkg-config +, rustPlatform +, withCmd ? false +}: + +rustPlatform.buildRustPackage rec { + pname = "kanata"; + version = "1.0.5"; + + src = fetchFromGitHub { + owner = "jtroo"; + repo = pname; + rev = "v${version}"; + sha256 = "sha256-sL9hP+222i8y0sK3ZEx66yXBTgZp5ewoPUlZS4XnphY="; + }; + + cargoHash = "sha256-uhN1UdwtU0C0/lpxUYoCcMLABFTPNO5wKsIGOBnFpzw="; + + buildFeatures = lib.optional withCmd "cmd"; + + nativeBuildInputs = [ pkg-config ]; + + buildInputs = [ libevdev ]; + + meta = with lib; { + description = "A cross-platform advanced keyboard customization tool"; + homepage = "https://github.com/jtroo/kanata"; + license = licenses.lgpl3Only; + maintainers = with maintainers; [ linj ]; + platforms = platforms.linux; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index ea1f578f461c..7386cc47be3e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1227,6 +1227,8 @@ with pkgs; httm = callPackage ../tools/filesystems/httm { }; + kanata = callPackage ../tools/system/kanata { }; + ksnip = libsForQt5.callPackage ../tools/misc/ksnip { }; kubevirt = callPackage ../tools/virtualization/kubevirt { };