kwm: init at 1.1.4

This commit is contained in:
Daiderd Jordan 2017-01-24 08:31:11 +01:00
parent 034d39b244
commit adfb7e1f13
No known key found for this signature in database
GPG Key ID: D02435D05B810C96
3 changed files with 79 additions and 0 deletions

@ -0,0 +1,42 @@
{ stdenv, fetchFromGitHub, Carbon, Cocoa }:
stdenv.mkDerivation rec {
name = "khd-${version}";
version = "1.1.4";
src = fetchFromGitHub {
owner = "koekeishiya";
repo = "khd";
rev = "v${version}";
sha256 = "1klia3fywl0c88zbp5wdn6kxhdwdry1jwmkj27vpv8vzvdfzwfmy";
};
buildInputs = [ Carbon Cocoa ];
prePatch = ''
substituteInPlace makefile \
--replace g++ clang++
'';
buildPhase = ''
make install
'';
installPhase = ''
mkdir -p $out/bin
cp bin/khd $out/bin/khd
mkdir -p $out/Library/LaunchDaemons
cp ${./org.nixos.khd.plist} $out/Library/LaunchDaemons/org.nixos.khd.plist
substituteInPlace $out/Library/LaunchDaemons/org.nixos.khd.plist --subst-var out
'';
meta = with stdenv.lib; {
description = "A simple modal hototkey daemon for OSX";
homepage = https://github.com/koekeishiya/khd;
downloadPage = https://github.com/koekeishiya/khd/releases;
platforms = platforms.darwin;
maintainers = with maintainers; [ lnl7 ];
license = licenses.mit;
};
}

@ -0,0 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>org.nixos.khd</string>
<key>ProgramArguments</key>
<array>
<string>@out@/bin/khd</string>
</array>
<key>KeepAlive</key>
<true/>
<key>ProcessType</key>
<string>Interactive</string>
<key>EnvironmentVariables</key>
<dict>
<key>PATH</key>
<string>@out@/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin</string>
</dict>
<key>Sockets</key>
<dict>
<key>Listeners</key>
<dict>
<key>SockServiceName</key>
<string>3021</string>
<key>SockType</key>
<string>dgram</string>
<key>SockFamily</key>
<string>IPv4</string>
</dict>
</dict>
</dict>
</plist>

@ -524,6 +524,10 @@ in
oracle-instantclient = callPackage ../development/libraries/oracle-instantclient { };
khd = callPackage ../os-specific/darwin/khd {
inherit (darwin.apple_sdk.frameworks) Carbon Cocoa;
};
reattach-to-user-namespace = callPackage ../os-specific/darwin/reattach-to-user-namespace {};
install_name_tool = callPackage ../os-specific/darwin/install_name_tool { };