basic emacs config

This commit is contained in:
Cyryl Płotnicki 2021-05-28 20:14:04 +01:00
parent 309433bd7b
commit e4f44574e0
2 changed files with 29 additions and 5 deletions

View file

@ -4,11 +4,15 @@ let
emacsWithPackages = (pkgs.emacsPackagesGen myEmacs).emacsWithPackages;
in
emacsWithPackages (epkgs: (with epkgs.melpaStablePackages; [
magit # ; Integrate git <C-x g>
zerodark-theme # ; Nicolas' theme
]) ++ (with epkgs.melpaPackages; [
]) ++ (with epkgs.elpaPackages; [
magit
solarized-theme
evil
])
++ (with epkgs.melpaPackages; [
xterm-color
nix-mode
])
++ (with epkgs.elpaPackages; [
beacon # ; highlight my cursor when scrolling
nameless # ; hide current package name everywhere in elisp code
]) ++ [

View file

@ -1,5 +1,25 @@
{ config, pkgs, ... }:
{
home.file.".emacs".text = ''
(require 'package)
;; optional. makes unpure packages archives unavailable
(setq package-archives nil)
(setq package-enable-at-startup nil)
(package-initialize)
(require 'xterm-color)
(progn (add-hook 'comint-preoutput-filter-functions 'xterm-color-filter)
(setq comint-output-filter-functions (remove 'ansi-color-process-output comint-output-filter-functions)))
(set-terminal-parameter nil 'background-mode 'dark)
(xterm-mouse-mode 1)
(require 'evil)
(evil-mode 1)
'';
programs.emacs = {
enable = true;
package = (import ./emacs.nix { inherit pkgs; });