fix: actually do home activation

This commit is contained in:
Noah Masur 2022-05-30 16:14:02 -04:00
parent 3656ed7e8f
commit 6f5b4725e7
2 changed files with 9 additions and 7 deletions

View File

@ -1,5 +1,5 @@
{ ... }: { { ... }: {
imports = [ ./neovim ./notes.nix ]; imports = [ ./neovim ./notes.nix ./dotfiles.nix ];
} }

View File

@ -5,12 +5,14 @@
home.activation = { home.activation = {
# Always clone dotfiles repository if it doesn't exist # Always clone dotfiles repository if it doesn't exist
cloneDotfiles = lib.hm.dag.entryAfter [ "writeBoundary" ] '' cloneDotfiles =
if [ ! -d "${config.dotfilesPath}" ]; then config.home-manager.users.${config.user}.lib.dag.entryAfter
$DRY_RUN_CMD mkdir --parents $VERBOSE_ARG $(dirname ${config.dotfilesPath}) [ "writeBoundary" ] ''
$DRY_RUN_CMD ${pkgs.git}/bin/git clone https://github.com/nmasur/dotfiles ${config.dotfilesPath} if [ ! -d "${config.dotfilesPath}" ]; then
fi $DRY_RUN_CMD mkdir --parents $VERBOSE_ARG $(dirname ${config.dotfilesPath})
''; $DRY_RUN_CMD ${pkgs.git}/bin/git clone https://github.com/nmasur/dotfiles ${config.dotfilesPath}
fi
'';
}; };