feat: use emacs29-pgtk on NixOS, and emacs29-macport for macOS

This commit is contained in:
Ryan Yin
2024-01-06 17:58:18 +08:00
parent 292809783d
commit daa883caf8
2 changed files with 18 additions and 14 deletions

View File

@@ -78,9 +78,11 @@ in {
}
(mkIf pkgs.stdenv.isLinux (
# Do not use emacs-nox here, which makes the mouse wheel work abnormally in terminal mode.
let
emacsPkg = pkgs.emacs29;
# Do not use emacs-nox here, which makes the mouse wheel work abnormally in terminal mode.
# pgtk (pure gtk) build add native support for wayland.
# https://www.gnu.org/savannah-checkouts/gnu/emacs/emacs.html#Releases
emacsPkg = pkgs.emacs29-pgtk;
in {
home.packages = [emacsPkg];
services.emacs = {
@@ -92,9 +94,10 @@ in {
))
(mkIf pkgs.stdenv.isDarwin (
# Do not use emacs-nox here, which makes the mouse wheel work abnormally in terminal mode.
let
emacsPkg = pkgs.emacs29;
# macport adds some native features based on GNU Emacs 29
# https://bitbucket.org/mituharu/emacs-mac/src/master/README-mac
emacsPkg = pkgs.emacs29-macport;
in {
home.packages = [emacsPkg];
launchd.enable = true;