Use emacsclient to update mu index to make sure the db isn't locked
This commit is contained in:
parent
2808ce7436
commit
8e1b901372
6 changed files with 401 additions and 377 deletions
|
@ -1,32 +1,49 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
let
|
||||
emacsPkg = pkgs.emacsWithPackagesFromUsePackage {
|
||||
config = ./emacs/init.el;
|
||||
package = pkgs.emacsPgtk;
|
||||
alwaysEnsure = true;
|
||||
extraEmacsPackages = epkgs: [
|
||||
# mu4e is included in the mu package and should be used from there
|
||||
pkgs.mu
|
||||
];
|
||||
};
|
||||
in
|
||||
{
|
||||
options.chvp.emacs = {
|
||||
enable = lib.mkOption {
|
||||
default = true;
|
||||
example = false;
|
||||
};
|
||||
package = lib.mkOption { };
|
||||
};
|
||||
|
||||
config = lib.mkIf config.chvp.emacs.enable {
|
||||
chvp = {
|
||||
emacs.package = emacsPkg;
|
||||
zfs.homeLinks = [
|
||||
{ path = ".emacs.d"; type = "cache"; }
|
||||
];
|
||||
};
|
||||
|
||||
home-manager.users.charlotte = { ... }: {
|
||||
programs.emacs = {
|
||||
services.emacs = {
|
||||
enable = true;
|
||||
package = pkgs.emacsWithPackagesFromUsePackage {
|
||||
config = ./emacs/init.el;
|
||||
package = pkgs.emacsPgtk;
|
||||
alwaysEnsure = true;
|
||||
extraEmacsPackages = epkgs: [
|
||||
# mu4e is included in the mu package and should be used from there
|
||||
pkgs.mu
|
||||
];
|
||||
};
|
||||
client.enable = true;
|
||||
package = emacsPkg;
|
||||
};
|
||||
home = {
|
||||
file = {
|
||||
".emacs.d/early-init.el".source = ./emacs/early-init.el;
|
||||
".emacs.d/init.el".source = ./emacs/init.el;
|
||||
};
|
||||
packages = [
|
||||
(pkgs.writeShellScriptBin "emacs" ''
|
||||
${emacsPkg}/bin/emacsclient -c $@
|
||||
'')
|
||||
];
|
||||
sessionVariables = { EDITOR = "emacs"; };
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue