nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 39 lines 1.3 kB view raw
1{ 2 lib, 3 stdenvNoCC, 4 fetchzip, 5}: 6stdenvNoCC.mkDerivation (finalAttrs: { 7 pname = "battery-toolkit"; 8 version = "1.8"; 9 10 src = fetchzip { 11 url = "https://github.com/mhaeuser/Battery-Toolkit/releases/download/${finalAttrs.version}/Battery-Toolkit-${finalAttrs.version}.zip"; 12 hash = "sha256-gsEXTE+pM+rsBhTeup7cWcUljY8u0T+ETON7JeA6g1A="; 13 stripRoot = false; 14 }; 15 16 installPhase = '' 17 runHook preInstall 18 19 mkdir -p "$out/Applications" 20 cp -R "Battery Toolkit.app" "$out/Applications/" 21 22 runHook postInstall 23 ''; 24 25 meta = { 26 description = "Control the platform power state of your Apple Silicon Mac"; 27 longDescription = '' 28 Battery Toolkit allows you to control battery charging behavior on Apple Silicon Macs. 29 Features include setting upper and lower charge limits, disabling the power adapter, 30 and manual control over charging state. 31 ''; 32 homepage = "https://github.com/mhaeuser/Battery-Toolkit"; 33 changelog = "https://github.com/mhaeuser/Battery-Toolkit/releases/tag/${finalAttrs.version}"; 34 license = lib.licenses.bsd3; 35 maintainers = with lib.maintainers; [ shgew ]; 36 platforms = [ "aarch64-darwin" ]; 37 sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ]; 38 }; 39})