diff options
author | Thomas Voss <mail@thomasvoss.com> | 2023-08-20 16:55:32 +0200 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2023-08-20 16:55:32 +0200 |
commit | 2d531217c586a45fbbf9e26a9792cb3a8e35c2ac (patch) | |
tree | 4520ea5abba91d632f8862d0ad31873488a7cb88 /.config | |
parent | e200e09688f2275da1055b6f86c3d400bdf3257e (diff) |
ec: Create a configuration file for ‘ec’
Diffstat (limited to '.config')
-rw-r--r-- | .config/ec/init.el | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/.config/ec/init.el b/.config/ec/init.el new file mode 100644 index 0000000..6de9f3c --- /dev/null +++ b/.config/ec/init.el @@ -0,0 +1,43 @@ +;; Disable useless visual elements +(menu-bar-mode -1) +(tool-bar-mode -1) +(scroll-bar-mode -1) + +;; XDG Directories +(defconst xdg-cache-home + (or (getenv "XDG_CACHE_HOME") + (expand-file-name ".cache" (getenv "HOME")))) +(defconst xdg-config-home + (or (getenv "XDG_CONFIG_HOME") + (expand-file-name ".config" (getenv "HOME")))) + +;; Keep the config directory clean +(let ((cache-dir (expand-file-name "ec" xdg-cache-home))) + (setq user-emacs-directory cache-dir + auto-save-list-file-prefix (expand-file-name + "auto-save-list/" + cache-dir) + backup-directory-alist `(("." . ,(expand-file-name + "backups" + cache-dir))))) + +;; Themeing +(add-to-list 'custom-theme-load-path (expand-file-name "emacs" xdg-config-home)) +(add-to-list 'default-frame-alist '(alpha-background . 90)) +(add-hook 'after-make-frame-functions + (lambda (_) + (dolist (face '(default fixed-pitch)) + (set-face-attribute face nil + :font "Iosevka Smooth" + :weight 'regular + :height 162)))) +(load-theme 'mango t) + +;; Set default settings +(with-eval-after-load 'calc + (setopt calc-show-banner nil + initial-buffer-choice (lambda () (get-buffer "*Calculator*"))) + (keymap-set calc-mode-map "q" #'delete-frame)) + +;; Enter ‘full-calc’ mode +(full-calc) |