2022-06-06 05:40:09 +02:00
|
|
|
;;; package --- Rawley Fowler's init.el
|
|
|
|
;;; Commentary:
|
|
|
|
;;; I used Vim for quite a few years, but evil mode Emacs
|
|
|
|
;;; is so much nicer.
|
2022-05-24 02:40:57 +02:00
|
|
|
;;; Code:
|
2022-05-21 22:33:15 +02:00
|
|
|
(menu-bar-mode -1)
|
|
|
|
(scroll-bar-mode -1)
|
|
|
|
(tool-bar-mode -1)
|
|
|
|
|
|
|
|
(set-language-environment "UTF-8")
|
|
|
|
(set-terminal-coding-system 'utf-8)
|
|
|
|
(set-keyboard-coding-system 'utf-8)
|
|
|
|
(set-selection-coding-system 'utf-8)
|
|
|
|
(prefer-coding-system 'utf-8)
|
|
|
|
(transient-mark-mode)
|
|
|
|
(show-paren-mode 1)
|
|
|
|
|
2022-06-06 05:40:09 +02:00
|
|
|
(defalias 'yes-or-no-p 'y-or-n-p)
|
2022-05-24 02:54:48 +02:00
|
|
|
|
2022-05-21 22:33:15 +02:00
|
|
|
(require 'package)
|
|
|
|
(add-to-list 'package-archives '("gnu" . "https://elpa.gnu.org/packages/"))
|
|
|
|
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/"))
|
|
|
|
(package-initialize)
|
|
|
|
|
|
|
|
(unless (package-installed-p 'use-package)
|
|
|
|
(package-refresh-contents)
|
|
|
|
(package-install 'use-package))
|
|
|
|
|
|
|
|
(eval-and-compile
|
|
|
|
(setq use-package-always-ensure t
|
2022-06-06 05:40:09 +02:00
|
|
|
use-package-expand-minimally t))
|
2022-05-21 22:33:15 +02:00
|
|
|
|
|
|
|
(require 'use-package)
|
|
|
|
|
2022-06-06 05:40:09 +02:00
|
|
|
;; Misc Packages
|
|
|
|
(use-package restart-emacs)
|
|
|
|
|
|
|
|
;; Theme
|
|
|
|
(use-package modus-themes
|
|
|
|
:init
|
|
|
|
(setq modus-themes-italic-constructs t
|
|
|
|
modus-themes-bold-constructs nil
|
|
|
|
modus-themes-region '(bg-only no-extend))
|
|
|
|
(modus-themes-load-themes)
|
|
|
|
:config
|
|
|
|
(modus-themes-load-operandi)
|
|
|
|
:bind
|
|
|
|
("<f5>" . modus-themes-toggle))
|
|
|
|
|
|
|
|
;; Evil.
|
2022-05-21 22:33:15 +02:00
|
|
|
(use-package evil
|
2022-06-06 05:40:09 +02:00
|
|
|
:ensure t
|
|
|
|
:init
|
2022-05-21 22:33:15 +02:00
|
|
|
(setq evil-want-integration t)
|
|
|
|
(setq evil-want-keybinding nil)
|
|
|
|
(setq evil-vsplit-window-right t)
|
|
|
|
(setq evil-split-window-below t)
|
|
|
|
(evil-mode))
|
2022-05-28 19:09:24 +02:00
|
|
|
|
2022-06-06 05:40:09 +02:00
|
|
|
(defun save-and-kill-this-buffer ()
|
2022-05-28 19:03:05 +02:00
|
|
|
(interactive)
|
|
|
|
(save-buffer)
|
2022-06-06 05:40:09 +02:00
|
|
|
(kill-current-buffer))
|
2022-05-28 19:09:24 +02:00
|
|
|
|
2022-05-21 22:33:15 +02:00
|
|
|
(use-package evil-collection
|
|
|
|
:after evil
|
|
|
|
:ensure t
|
|
|
|
:config
|
|
|
|
(evil-collection-init))
|
|
|
|
|
2022-05-29 02:51:51 +02:00
|
|
|
(use-package evil-org)
|
|
|
|
|
2022-06-06 05:40:09 +02:00
|
|
|
;; Other configs
|
|
|
|
(load-file "~/.emacs.d/lsp.el")
|
|
|
|
(load-file "~/.emacs.d/modes.el")
|
|
|
|
(load-file "~/.emacs.d/extra.el")
|
|
|
|
(load-file "~/.emacs.d/bind.el")
|
2022-05-21 22:33:15 +02:00
|
|
|
|
|
|
|
(custom-set-variables
|
|
|
|
;; custom-set-variables was added by Custom.
|
|
|
|
;; If you edit it by hand, you could mess it up, so be careful.
|
|
|
|
;; Your init file should contain only one such instance.
|
|
|
|
;; If there is more than one, they won't work right.
|
2022-05-22 18:30:17 +02:00
|
|
|
'(helm-minibuffer-history-key "M-p")
|
2022-06-06 05:40:09 +02:00
|
|
|
'(package-selected-packages '(evil-org evil-collection evil use-package)))
|
2022-05-21 22:33:15 +02:00
|
|
|
(custom-set-faces
|
|
|
|
;; custom-set-faces was added by Custom.
|
|
|
|
;; If you edit it by hand, you could mess it up, so be careful.
|
|
|
|
;; Your init file should contain only one such instance.
|
|
|
|
;; If there is more than one, they won't work right.
|
|
|
|
)
|
2022-06-06 05:40:09 +02:00
|
|
|
|
|
|
|
;;; init.el ends here
|