diff options
author | Kjetil Ørbekk <kjetil.orbekk@gmail.com> | 2016-11-07 20:46:34 -0500 |
---|---|---|
committer | Franz Pletz <fpletz@fnordicwalking.de> | 2016-11-08 02:46:34 +0100 |
commit | 0d5caf138a6dd38fe1cb085f01e1c216ce026890 (patch) | |
tree | 57c908ad05b3ef43db58fb335756dd00677a0da4 | |
parent | ee5af3fb668a99f203416a87237f2c2ff85d0b79 (diff) | |
download | nixpkgs-0d5caf138a6dd38fe1cb085f01e1c216ce026890.tar nixpkgs-0d5caf138a6dd38fe1cb085f01e1c216ce026890.tar.gz nixpkgs-0d5caf138a6dd38fe1cb085f01e1c216ce026890.tar.bz2 nixpkgs-0d5caf138a6dd38fe1cb085f01e1c216ce026890.tar.lz nixpkgs-0d5caf138a6dd38fe1cb085f01e1c216ce026890.tar.xz nixpkgs-0d5caf138a6dd38fe1cb085f01e1c216ce026890.tar.zst nixpkgs-0d5caf138a6dd38fe1cb085f01e1c216ce026890.zip |
tpacpi-bat: init at 3.0 (#20213)
-rw-r--r-- | lib/maintainers.nix | 1 | ||||
-rw-r--r-- | pkgs/os-specific/linux/tpacpi-bat/default.nix | 32 | ||||
-rw-r--r-- | pkgs/top-level/all-packages.nix | 2 |
3 files changed, 35 insertions, 0 deletions
diff --git a/lib/maintainers.nix b/lib/maintainers.nix index e463e852933..28ff28fba71 100644 --- a/lib/maintainers.nix +++ b/lib/maintainers.nix @@ -318,6 +318,7 @@ offline = "Jaka Hudoklin <jakahudoklin@gmail.com>"; olcai = "Erik Timan <dev@timan.info>"; olejorgenb = "Ole Jørgen Brønner <olejorgenb@yahoo.no>"; + orbekk = "KJ Ørbekk <kjetil.orbekk@gmail.com>"; orbitz = "Malcolm Matalka <mmatalka@gmail.com>"; osener = "Ozan Sener <ozan@ozansener.com>"; otwieracz = "Slawomir Gonet <slawek@otwiera.cz>"; diff --git a/pkgs/os-specific/linux/tpacpi-bat/default.nix b/pkgs/os-specific/linux/tpacpi-bat/default.nix new file mode 100644 index 00000000000..bf60331d8ad --- /dev/null +++ b/pkgs/os-specific/linux/tpacpi-bat/default.nix @@ -0,0 +1,32 @@ +{ stdenv, fetchFromGitHub, perl, kmod }: + +# Requires the acpi_call kernel module in order to run. +stdenv.mkDerivation rec { + name = "tpacpi-bat-${version}"; + version = "3.0"; + + src = fetchFromGitHub { + owner = "teleshoes"; + repo = "tpacpi-bat"; + rev = "v${version}"; + sha256 = "0l72qvjk5j7sg9x4by7an0xwx65x10dx82fky8lnwlwfv54vgg8l"; + }; + + buildInputs = [ perl ]; + + installPhase = '' + mkdir -p $out/bin + cp tpacpi-bat $out/bin + ''; + + postPatch = '' + substituteInPlace tpacpi-bat --replace modprobe ${kmod}/bin/modprobe + ''; + + meta = { + maintainers = [stdenv.lib.maintainers.orbekk]; + platforms = stdenv.lib.platforms.linux; + description = "Tool to set battery charging thesholds on Lenovo Thinkpad"; + license = stdenv.lib.licenses.gpl3Plus; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c3d2053f9cb..8c21249c247 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -11413,6 +11413,8 @@ in tiptop = callPackage ../os-specific/linux/tiptop { }; + tpacpi-bat = callPackage ../os-specific/linux/tpacpi-bat { }; + trinity = callPackage ../os-specific/linux/trinity { }; tunctl = callPackage ../os-specific/linux/tunctl { }; |