nvim systemd for cloning

This commit is contained in:
2026-01-30 20:24:40 -06:00
parent 4b4e3a95bf
commit 835e7498e4

View File

@@ -1,9 +1,24 @@
{ config, pkgs, ... }:
{ {
hj.files."./.config/nvim" = { systemd.user.services."nvim-config" = {
source = builtins.fetchGit { description = "Clone Neovim config into ~/.config/nvim";
url = "https://git.archfox.org/poslop/nvbad.git"; after = [ "network.target" ];
rev = "eab1653d4e3663562c597bab493eeb12d94d905c"; wantedBy = [ "default.target" ];
enable = true;
serviceConfig = {
Type = "oneshot";
}; };
uid = "poslop";
script = ''
set -e
if [ ! -d "$HOME/.config/nvim/.git" ]; then
echo "Cloning Neovim config..."
${pkgs.git}/bin/git clone https://git.archfox.org/poslop/nvbad.git "$HOME/.config/nvim"
else
echo "Neovim config already exists, skipping."
fi
'';
}; };
} }