feat: Add spacemacs module and update system
This commit is contained in:
parent
63ab4323a5
commit
8fec2465d3
6 changed files with 238 additions and 106 deletions
51
home/david/modules/programs/spacemacs/default.nix
Normal file
51
home/david/modules/programs/spacemacs/default.nix
Normal file
|
|
@ -0,0 +1,51 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
inputs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (inputs) nixpkgs emacs-overlay spacemacs;
|
||||
inherit (pkgs) system;
|
||||
cfg = config.david.programs.spacemacs;
|
||||
pkgs' = import nixpkgs {
|
||||
inherit system;
|
||||
overlays = [ emacs-overlay.overlays.default ];
|
||||
};
|
||||
in
|
||||
{
|
||||
options = {
|
||||
david.programs.spacemacs = {
|
||||
enable = lib.mkEnableOption "spacemacs";
|
||||
};
|
||||
};
|
||||
config = lib.mkIf cfg.enable {
|
||||
stylix.targets.emacs.enable = false;
|
||||
xdg.configFile = {
|
||||
emacs = {
|
||||
source = "${spacemacs}";
|
||||
recursive = true;
|
||||
};
|
||||
};
|
||||
programs.emacs = {
|
||||
enable = true;
|
||||
package =
|
||||
with pkgs';
|
||||
(emacsPackagesFor emacs-pgtk).emacsWithPackages (epkgs: [
|
||||
git
|
||||
gnutar
|
||||
ripgrep
|
||||
]);
|
||||
};
|
||||
services.emacs = {
|
||||
client = {
|
||||
enable = true;
|
||||
};
|
||||
defaultEditor = false;
|
||||
enable = true;
|
||||
socketActivation.enable = true;
|
||||
startWithUserSession = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue