home: move emacs service to home config

This commit is contained in:
Antoine Martin 2021-04-19 15:42:27 +02:00
parent 6b660a74ef
commit cc34396e9e
4 changed files with 21 additions and 5 deletions

View file

@ -1,6 +1,7 @@
{ ... }:
{
imports = [
./emacs.nix
./x
];

19
home/emacs.nix Normal file
View file

@ -0,0 +1,19 @@
{ config, lib, pkgs, ... }:
{
options.my.home.emacs = with lib; {
enable = mkEnableOption "Emacs daemon configuration";
};
config = lib.mkIf config.my.home.emacs.enable {
services.emacs = {
enable = true;
# generate emacsclient desktop file
client.enable = true;
};
programs.emacs = {
enable = true;
package = pkgs.emacsPgtkGcc;
};
};
}

View file

@ -71,11 +71,6 @@ in
layout = "fr";
xkbVariant = "us";
};
emacs = {
enable = true;
package = pkgs.emacsPgtkGcc;
};
};
sound.enable = true;

View file

@ -3,5 +3,6 @@
home-manager.users.alarsyo = {
# Keyboard settings & i3 settings
my.home.x.enable = true;
my.home.emacs.enable = true;
};
}