Pārlūkot izejas kodu

Tons of changes to .emacs. Trying to clean it up and modernize a bit

Simon Watson 2 gadi atpakaļ
vecāks
revīzija
6e33ecccff
2 mainītis faili ar 48 papildinājumiem un 13 dzēšanām
  1. 42 13
      emacs/.emacs-all
  2. 6 0
      emacs/yasnippets/emacs-lisp-mode/straight-use-package

+ 42 - 13
emacs/.emacs-all

@@ -23,7 +23,6 @@
 (straight-use-package 'all-the-icons)
 (straight-use-package 'neotree)
 (straight-use-package 'rust-mode)
-(straight-use-package 'powerline)
 (straight-use-package 'markdown-mode)
 (straight-use-package 'moe-theme)
 (straight-use-package 'ample-theme)
@@ -33,7 +32,6 @@
 (straight-use-package 'dimmer)
 (straight-use-package 'magit)
 (straight-use-package 'diff-hl)
-(straight-use-package 'powerline-evil)
 (straight-use-package 'rainbow-delimiters)
 (straight-use-package 'focus)
 (straight-use-package 'solarized-theme)
@@ -66,6 +64,7 @@
   (let ((inhibit-read-only t))
     (ansi-color-apply-on-region (point-min) (point-max))))
 
+;;; Terminal in emacs via vterm lib
 (straight-use-package
  '(vterm :type git :host github
    :repo "akermu/emacs-libvterm"))
@@ -77,13 +76,44 @@
             (set (make-local-variable 'buffer-face-mode-face) 'fixed-pitch)
             (buffer-face-mode t)))
 
+;;; Syntax highlights for uxn-tal
 (straight-use-package
  '(tal-mode :type git :host github
    :repo "rafapaezbas/uxntal-mode"))
 
-;;(straight-use-package
-;; '(org :type git :repo "https://git.savannah.gnu.org/git/emacs/org-mode.git"))
-;;(require 'org)
+;;; Cursor highlighter
+(straight-use-package
+ '(beacon :type git :host github
+   :repo "Malabarba/beacon"))
+
+(global-set-key (kbd "C-c B") 'beacon-mode)
+
+;; Vimperator like hints for
+;; file navigationaki2o/emacs-pophint
+(straight-use-package
+  '(pophint :type git :host github
+	    :repo "aki2o/emacs-pophint"))
+
+(global-set-key (kbd "C-c f") 'pophint:do-flexibly)
+
+;;; Code folding
+(add-hook 'perl-mode-hook 'hs-minor-mode)
+(add-hook 'lisp-mode-hook 'hs-minor-mode)
+(add-hook 'emacs-lisp-mode-hook 'hs-minor-mode)
+
+(global-set-key (kbd "C-c a") 'hs-toggle-hiding)
+
+;;; Error checking
+(global-set-key (kbd "C-c 2 e") 'flymake-mode)
+
+;; System monitor
+(straight-use-package
+ '(symon :type git :host github
+	 :repo "zk-phi/symon"))
+
+(straight-use-package
+ '(telephone-line :type git :host github
+		  :repo "dbordak/telephone-line"))
 
 (require 'yasnippet)
 
@@ -134,12 +164,6 @@
 
 (require 'markdown-mode)
 
-(require 'powerline)
-;;(powerline-default-theme)
-;; Better powerline support for evil mode
-(require 'powerline-evil)
-(powerline-evil-vim-color-theme)
-
 (require 'neotree)
 (global-set-key [f8] 'neotree-toggle)
 
@@ -190,15 +214,20 @@
 (global-set-key (kbd "C-c ;") 'comment-line)
 (global-set-key (kbd "C-c b") 'fzf-switch-buffer)
 (global-set-key (kbd "C-c z") 'fzf-find-file)
-(global-set-key (kbd "C-c e") 'diff-hl-mode)
+(defun wrap-diff-hl-enable ()
+  (interactive)
+  (diff-hl-mode)
+  (diff-hl-flydiff-mode))
+(global-set-key (kbd "C-c e") 'wrap-diff-hl-enable)
 (global-set-key (kbd "C-c d") 'slime-describe-symbol)
 (global-set-key (kbd "C-c M-r") 'slime-restart-inferior-lisp)
 (global-set-key (kbd "C-c D") 'dimmer-mode)
 (global-set-key (kbd "C-c s") 'sublimity-mode)
-(global-set-key (kbd "C-c f") 'focus-mode)
+(global-set-key (kbd "C-c F") 'focus-mode)
 (global-set-key (kbd "C-c r") 'reload-dot-emacs)
 (global-set-key (kbd "C-c l") 'display-line-numbers-mode)
 (global-set-key (kbd "C-c w") 'windresize)
+(global-set-key (kbd "C-c W") 'whitespace-mode)
 (global-set-key (kbd "C-c t") 'sol-dk)
 (global-set-key (kbd "C-c y") 'sol-l) ; Quick toggle evil-mode for slime err
 (global-set-key (kbd "C-c g") 'magit)

+ 6 - 0
emacs/yasnippets/emacs-lisp-mode/straight-use-package

@@ -0,0 +1,6 @@
+# -*- mode: snippet -*-
+# name: straight-use-package elisp
+# key: /sup
+# --
+(straight-use-package
+  '(${1:pkg-name}