From 901fe1c66164d85697f35be573abd24493bf9324 Mon Sep 17 00:00:00 2001 From: Evie Litherland-Smith Date: Sat, 17 Feb 2024 19:10:22 +0000 Subject: [PATCH] Remove emacs-sync-config.sh Go back to simple git command in hyprland extraConfig --- home/hyprland/default.nix | 9 ++------- home/scripts/default.nix | 2 -- home/scripts/emacs-sync-config.sh | 8 -------- 3 files changed, 2 insertions(+), 17 deletions(-) delete mode 100644 home/scripts/emacs-sync-config.sh diff --git a/home/hyprland/default.nix b/home/hyprland/default.nix index e4d4f183..e4120ecf 100644 --- a/home/hyprland/default.nix +++ b/home/hyprland/default.nix @@ -327,15 +327,10 @@ "SUPER, mouse:273, resizewindow" ]; }; - extraConfig = let - emacs-sync = let - name = "emacs-sync-config"; - script = builtins.readFile ../scripts/emacs-sync-config.sh; - in "${pkgs.writeShellScriptBin name script}/bin/${name}"; - in '' + extraConfig = '' exec-once = systemctl --user import-environment WAYLAND_DISPLAY QT_QPA_PLATFORMTHEME exec-once = systemctl --user restart "xdg-desktop-portal*" - exec-once = ${emacs-sync} + exec-once = ${pkgs.git}/bin/git -C ${config.xdg.configHome}/emacs pull --ff-only ''; }; } diff --git a/home/scripts/default.nix b/home/scripts/default.nix index e339c1c1..20aedf51 100644 --- a/home/scripts/default.nix +++ b/home/scripts/default.nix @@ -2,8 +2,6 @@ home.packages = [ (pkgs.writeShellScriptBin "git-sync-all" (builtins.readFile ./git-sync-all.sh)) - (pkgs.writeShellScriptBin "emacs-sync-config" - (builtins.readFile ./emacs-sync-config.sh)) (pkgs.writeShellScriptBin "rsync-local-config" (builtins.readFile ./rsync-local-config.sh)) (pkgs.writeShellScriptBin "xdg-query-program" diff --git a/home/scripts/emacs-sync-config.sh b/home/scripts/emacs-sync-config.sh deleted file mode 100644 index d8647202..00000000 --- a/home/scripts/emacs-sync-config.sh +++ /dev/null @@ -1,8 +0,0 @@ -EMACS_DIR="$HOME/.emacs.d" -EMACS_CONF_URL="https://git.xenia.me.uk/xenia/emacs" - -if [ ! -d "$EMACS_DIR" ]; then - git clone "$EMACS_CONF_URL" "$EMACS_DIR" -fi - -git -C "$EMACS_DIR" pull --ff-only