infra/nix/home-manager/programs/homeshick.nix

38 lines
896 B
Nix
Raw Normal View History

2022-10-31 11:04:38 +01:00
{ pkgs, config, ... }:
let
# TODO: clean up the impurity in here
in {
2022-10-31 11:04:38 +01:00
home.sessionVariables = { HOMESHICK_DIR = "${pkgs.homeshick}"; };
2022-10-31 11:04:38 +01:00
home.activation.bootstrapRepos =
config.lib.dag.entryAfter [ "writeBoundary" ] ''
$DRY_RUN_CMD ${
pkgs.writeScript "activation-script" ''
set -e
echo home-manager path is ${config.home.path}
echo home is $HOME
2022-10-31 11:04:38 +01:00
source ${pkgs.homeshick}/homeshick.sh
type homeshick
# echo Updating homeshick
# ln -sfT ${pkgs.homeshick} "$HOMESICK_REPOS"/.homeshick
# mv -Tf "$HOMESICK_REPOS"/{.,}homeshick
''
};
'';
nixpkgs.config = {
2022-10-31 11:04:38 +01:00
packageOverrides = pkgs:
with pkgs; {
homeshick = builtins.fetchGit {
url = "https://github.com/andsens/homeshick.git";
ref = "master";
};
};
};
}