2017-12-30 00:52:26 +00:00
|
|
|
#Adapted from
|
2019-04-26 13:09:11 +01:00
|
|
|
#https://github.com/rycee/home-manager/blob/2c07829be2bcae55e04997b19719ff902a44016d/home-manager/default.nix
|
2017-12-30 00:52:26 +00:00
|
|
|
|
2019-04-26 13:09:11 +01:00
|
|
|
{ bash, coreutils, findutils, gnused, less, stdenv, makeWrapper, fetchFromGitHub }:
|
2017-12-30 00:52:26 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "home-manager";
|
2019-11-18 07:31:37 +00:00
|
|
|
version = "2019-11-17";
|
2017-12-30 00:52:26 +00:00
|
|
|
|
2018-11-15 10:35:05 +00:00
|
|
|
src = fetchFromGitHub {
|
2017-12-30 00:52:26 +00:00
|
|
|
owner = "rycee";
|
|
|
|
repo = "home-manager";
|
2019-11-18 07:31:37 +00:00
|
|
|
rev = "286dd9b3088298e5a4625b517f8e72b1c62e4f74";
|
|
|
|
sha256 = "0p3ba287h9a7mpj8chdgvz5qryc15qxdis3fdmv9jvl0hwsr738d";
|
2017-12-30 00:52:26 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
dontBuild = true;
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
install -v -D -m755 ${src}/home-manager/home-manager $out/bin/home-manager
|
|
|
|
|
|
|
|
substituteInPlace $out/bin/home-manager \
|
|
|
|
--subst-var-by bash "${bash}" \
|
|
|
|
--subst-var-by coreutils "${coreutils}" \
|
2019-04-26 13:09:11 +01:00
|
|
|
--subst-var-by findutils "${findutils}" \
|
|
|
|
--subst-var-by gnused "${gnused}" \
|
2017-12-30 00:52:26 +00:00
|
|
|
--subst-var-by less "${less}" \
|
|
|
|
--subst-var-by HOME_MANAGER_PATH '${src}'
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A user environment configurator";
|
|
|
|
maintainers = with maintainers; [ rycee ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|