Define emacs in one place
This commit is contained in:
parent
fab03630a5
commit
e152da7a94
4 changed files with 22 additions and 33 deletions
|
|
@ -17,16 +17,8 @@
|
||||||
nfs-utils
|
nfs-utils
|
||||||
sshfs
|
sshfs
|
||||||
|
|
||||||
# unstable.emacs
|
myEmacs
|
||||||
#
|
|
||||||
# Probably this is being overwritten by home-manager.
|
|
||||||
#
|
|
||||||
# TODO: Resolve the disparity.
|
|
||||||
((emacsPackagesFor emacs-unstable).emacsWithPackages
|
|
||||||
(epkgs: with epkgs; [
|
|
||||||
treesit-grammars.with-all-grammars
|
|
||||||
mu4e
|
|
||||||
]))
|
|
||||||
notmuch mu isync
|
notmuch mu isync
|
||||||
keychain ledger gnupg
|
keychain ledger gnupg
|
||||||
ledger2beancount beancount fava
|
ledger2beancount beancount fava
|
||||||
|
|
|
||||||
|
|
@ -1,12 +1,4 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
let
|
|
||||||
emacs =
|
|
||||||
((pkgs.emacsPackagesFor pkgs.emacs-unstable).emacsWithPackages
|
|
||||||
(epkgs: with epkgs; [
|
|
||||||
treesit-grammars.with-all-grammars
|
|
||||||
mu4e
|
|
||||||
]));
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
picom
|
picom
|
||||||
|
|
@ -19,7 +11,7 @@ in
|
||||||
windowManager.session = [{
|
windowManager.session = [{
|
||||||
name = "my-exwm";
|
name = "my-exwm";
|
||||||
start = ''
|
start = ''
|
||||||
${emacs}/bin/emacs -l /home/benson/.emacs.d/init.el
|
${pkgs.myEmacs}/bin/emacs -l /home/benson/.emacs.d/init.el
|
||||||
'';
|
'';
|
||||||
}];
|
}];
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -10,4 +10,20 @@ inputs:
|
||||||
dontStrip = true;
|
dontStrip = true;
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
|
|
||||||
|
(final: prev:
|
||||||
|
let
|
||||||
|
emacs-with-xrandr = final.emacs-unstable.overrideAttrs (
|
||||||
|
oa: {
|
||||||
|
buildInputs = oa.buildInputs ++ [ prev.xorg.libXrandr ];
|
||||||
|
}
|
||||||
|
);
|
||||||
|
in {
|
||||||
|
myEmacs =
|
||||||
|
((prev.emacsPackagesFor emacs-with-xrandr)
|
||||||
|
.emacsWithPackages (epkgs: with epkgs; [
|
||||||
|
treesit-grammars.with-all-grammars
|
||||||
|
mu4e
|
||||||
|
]));
|
||||||
|
})
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -1,16 +1,5 @@
|
||||||
{ inputs, config, pkgs, lib, ... }@args:
|
{ inputs, config, pkgs, lib, ... }@args:
|
||||||
let
|
{
|
||||||
emacs-with-xrandr = pkgs.emacs-unstable.overrideAttrs (
|
|
||||||
oa: {
|
|
||||||
buildInputs = oa.buildInputs ++ [ pkgs.xorg.libXrandr ];
|
|
||||||
}
|
|
||||||
);
|
|
||||||
my-emacs = ((pkgs.emacsPackagesFor emacs-with-xrandr)
|
|
||||||
.emacsWithPackages (epkgs: with epkgs; [
|
|
||||||
treesit-grammars.with-all-grammars
|
|
||||||
mu4e
|
|
||||||
]));
|
|
||||||
in {
|
|
||||||
imports = [
|
imports = [
|
||||||
../modules
|
../modules
|
||||||
../../submodules
|
../../submodules
|
||||||
|
|
@ -113,7 +102,7 @@ in {
|
||||||
smtp.host = "smtp.fastmail.com";
|
smtp.host = "smtp.fastmail.com";
|
||||||
|
|
||||||
userName = "bensonchu@fastmail.com";
|
userName = "bensonchu@fastmail.com";
|
||||||
passwordCommand = ''${my-emacs}/bin/emacsclient -e '(get-authinfo "imap.fastmail.com" "993" "bensonchu457@fastmail.com")' | ${pkgs.coreutils}/bin/tr -d '"' '';
|
passwordCommand = ''${pkgs.myEmacs}/bin/emacsclient -e '(get-authinfo "imap.fastmail.com" "993" "bensonchu457@fastmail.com")' | ${pkgs.coreutils}/bin/tr -d '"' '';
|
||||||
|
|
||||||
mu.enable = true;
|
mu.enable = true;
|
||||||
};
|
};
|
||||||
|
|
@ -134,7 +123,7 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
emacs = {
|
emacs = {
|
||||||
package = my-emacs;
|
package = pkgs.myEmacs;
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue