From 92b6e0e3255e8ff515db22919edee14f34db2d03 Mon Sep 17 00:00:00 2001 From: Evie Litherland-Smith Date: Tue, 10 Dec 2024 14:57:32 +0000 Subject: [PATCH] Don't use Emacs service on laptops or server, only desktops --- system/Legion.nix | 1 + system/home/emacs/default.nix | 10 +++++++--- system/laptop.nix | 1 + 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/system/Legion.nix b/system/Legion.nix index 87c7d507..ad12989a 100644 --- a/system/Legion.nix +++ b/system/Legion.nix @@ -19,6 +19,7 @@ }; home-manager.users.${username} = { imports = [ ./home/emacs/default.nix ]; + services.emacs.enable = false; home.stateVersion = "23.05"; }; system.stateVersion = "23.05"; diff --git a/system/home/emacs/default.nix b/system/home/emacs/default.nix index c9e61e42..7d14dc5a 100644 --- a/system/home/emacs/default.nix +++ b/system/home/emacs/default.nix @@ -1,4 +1,9 @@ -{ config, pkgs, ... }: +{ + config, + lib, + pkgs, + ... +}: { imports = [ ../shell/default.nix @@ -14,7 +19,7 @@ base16-theme-highlight-mode-line 'contrast) ''; services.emacs = { - enable = true; + enable = lib.mkDefault true; package = config.programs.emacs.finalPackage; defaultEditor = true; client.enable = true; @@ -22,7 +27,6 @@ startWithUserSession = "graphical"; }; programs.emacs = { - # Clone emacs config from https://git.xenia.me.uk/pixelifytica/emacs.git enable = true; package = pkgs.emacs29.override { withImageMagick = true; diff --git a/system/laptop.nix b/system/laptop.nix index aa95a4d3..6c3cbc1e 100644 --- a/system/laptop.nix +++ b/system/laptop.nix @@ -4,6 +4,7 @@ environment.systemPackages = [ pkgs.acpi ]; powerManagement.enable = true; networking.networkmanager.wifi.powersave = true; + services.emacs.enable = false; services.auto-cpufreq = { enable = false; # TEMP, conflict with power-profiles-daemon settings = {