forked from mirrors/nixpkgs
0dd7d213c2
home-manager: init at 2017-12-07
39 lines
1 KiB
Nix
39 lines
1 KiB
Nix
#Adapted from
|
|
#https://github.com/rycee/home-manager/blob/9c1b3735b402346533449efc741f191d6ef578dd/home-manager/default.nix
|
|
|
|
{ bash, coreutils, less, stdenv, makeWrapper, fetchFromGitHub }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "home-manager-${version}";
|
|
version = "2017-12-7";
|
|
|
|
src = fetchFromGitHub{
|
|
owner = "rycee";
|
|
repo = "home-manager";
|
|
rev = "0be32c9d42e3a8739263ae7886dc2448c833c19c";
|
|
sha256 = "06lmnzlf5fmiicbgai27ad9m3bj980xf8ifdpc5lzbsy77pfcfap";
|
|
};
|
|
|
|
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}" \
|
|
--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;
|
|
};
|
|
|
|
}
|