summaryrefslogtreecommitdiff
path: root/emacs
diff options
context:
space:
mode:
authortslil <>2021-07-25 18:12:57 -0400
committertslil <>2021-07-25 18:12:57 -0400
commit30d95d77e69ad9c3055881f900d6a204557aa191 (patch)
tree35591799813f1587cb9844fa45a8e73663692863 /emacs
parentb5adde6a3727dab35a987467700c82f7478732ec (diff)
parent0da02b29d9f7a90c6bfd6fadf299d12ea0142b92 (diff)
Merge branch 'master' of git.sr.ht:~tslil/dotfiles
Diffstat (limited to 'emacs')
-rw-r--r--emacs/inits/14-movement.el85
-rw-r--r--emacs/inits/21-functional.el35
2 files changed, 45 insertions, 75 deletions
diff --git a/emacs/inits/14-movement.el b/emacs/inits/14-movement.el
index 4752d02..22f5c54 100644
--- a/emacs/inits/14-movement.el
+++ b/emacs/inits/14-movement.el
@@ -1,4 +1,4 @@
-;; Time-stamp: <2021-01-09 01:19:05 (tslil@bison)>
+;; Time-stamp: <2021-07-03 17h13 EDT (hobbies)>
;; -------------------------------------------------------------------
;; Repeated key presses for region
@@ -13,68 +13,59 @@
;; -------------------------------------------------------------------
;; Window switching
+
(use-package switch-window :ensure t
:bind (("C-x o" . switch-window)
- ("C-x C-o" . other-frame)
- ("C-c o" . switch-window)
- ("C-c n" . switch-window-then-maximize)
- :map switch-window-extra-map
- ("u" . switch-window-mvborder-up)
- ("e" . switch-window-mvborder-down)
- ("n" . switch-window-mvborder-left)
- ("o" . switch-window-mvborder-right)
- ("i" . nil)
- ("j" . nil)
- ("k" . nil)
- ("l" . nil))
+ ("C-x C-o" . other-frame)
+ ("C-c o" . switch-window)
+ ("C-c n" . switch-window-then-maximize)
+ :map switch-window-extra-map
+ ("u" . switch-window-mvborder-up)
+ ("e" . switch-window-mvborder-down)
+ ("n" . switch-window-mvborder-left)
+ ("o" . switch-window-mvborder-right)
+ ("i" . nil)
+ ("j" . nil)
+ ("k" . nil)
+ ("l" . nil))
:config
(setq switch-window-input-style 'minibuffer
- switch-window-shortcut-style 'qwerty
- switch-window-multiple-frames nil
- switch-window-qwerty-shortcuts
- '("a" "r" "s" "t" "n" "e" "i" "o")))
+ switch-window-shortcut-style 'qwerty
+ switch-window-multiple-frames nil
+ switch-window-qwerty-shortcuts
+ '("a" "r" "s" "t" "n" "e" "i" "o")))
;; -------------------------------------------------------------------
;; Character jumping
+
(use-package avy
:ensure t
:demand
:bind (("C-," . avy-goto-char-timer)
- ("C-." . avy-goto-char-in-line)
- ("M-g s" . avy-goto-word-or-subword-1)
- ("M-g w" . avy-goto-word-1)
- ("M-g a" . avy-goto-word-0)
- ("M-g M-g" . avy-goto-line))
+ ("C-." . avy-goto-char-in-line)
+ ("M-g s" . avy-goto-word-or-subword-1)
+ ("M-g w" . avy-goto-word-1)
+ ("M-g a" . avy-goto-word-0)
+ ("M-g C-g" . avy-goto-line))
:config
(setq avy-keys '(?a ?r ?s ?t ?g ?k ?n ?e ?i ?o ?q ?w ?f ?p)
- avy-dispatch-alist '((?w . avy-action-kill-move)
- (?W . avy-action-kill-stay)
- (?j . avy-action-teleport)
- (?m . avy-action-mark)
- (?c . avy-action-copy)
- (?y . avy-action-yank)
- (?i . avy-action-ispell)
- (?z . avy-action-zap-to-char))))
-
-(use-package frog-jump-buffer
- :ensure t
- :bind (("M-SPC" . frog-jump-buffer))
- :config
- (custom-set-faces
- '(frog-menu-posframe-background-face ((t (:background "#282828"))))
- '(frog-menu-action-keybinding-face ((t (:inherit link))))
- '(frog-menu-prompt-face ((t (:background "#b8bb26" :foreground "#282828"))))
- '(frog-menu-border ((t (:background "dark orange"))))
- '(frog-menu-candidates-face ((t (:inherit default)))))
- (setq frog-jump-buffer-ignore-buffers '("\\` " "*")
- frog-menu-posframe-border-width 3
- frog-menu-avy-keys '(?a ?r ?s ?t ?g ?k ?n ?e ?i ?o ?'
- ?q ?w ?f ?p ?b ?j ?l ?u ?y ?\;
- ?z ?x ?c ?d ?v ?m ?h ?, ?.)))
+ avy-dispatch-alist '((?w . avy-action-kill-move)
+ (?W . avy-action-kill-stay)
+ (?j . avy-action-teleport)
+ (?m . avy-action-mark)
+ (?c . avy-action-copy)
+ (?y . avy-action-yank)
+ (?i . avy-action-ispell)
+ (?z . avy-action-zap-to-char))))
;; -------------------------------------------------------------------
;; General stuff
+;; (global-set-key (kbd "C-b") 'recenter-top-bottom)
+;; (global-set-key (kbd "M-b") 'downcase-word)
+;; (global-set-key (kbd "C-l") 'backward-char)
+;; (global-set-key (kbd "M-l") 'backward-word)
+
(global-set-key (kbd "C-M-e") 'end-of-buffer)
(global-set-key (kbd "C-M-a") 'beginning-of-buffer)
@@ -99,7 +90,7 @@
(lambda () (interactive) (ignore-errors (backward-char 5))))
;; Hardcore mode
-(defconst hardcore-nav-mode t)
+(defconst hardcore-nav-mode nil)
(when hardcore-nav-mode
(global-set-key (kbd "<XF86Back>") nil)
(global-set-key (kbd "<XF86Forward>") nil)
diff --git a/emacs/inits/21-functional.el b/emacs/inits/21-functional.el
index 07aaede..f863145 100644
--- a/emacs/inits/21-functional.el
+++ b/emacs/inits/21-functional.el
@@ -1,24 +1,14 @@
-;; Time-stamp: <2019-02-02 18:55:41 (tslil@winslow)>
+;; Time-stamp: <2021-07-07 19h56 EDT (hobbies)>
;; -----------------------------------------------------------------------------
;; Haskell
-(use-package ghc :ensure t :defer t)
-
-(use-package company-ghc :ensure t :defer t)
-
-(use-package company-ghci :ensure t :defer t)
-
-(use-package shm :ensure t
- :functions structured-haskell-mode
- :bind (:map shm-map
- ("C-c C-s" . shm/case-split)))
+(use-package lsp-haskell :ensure t :defer)
(use-package haskell-mode
:ensure t
- :after (company-ghc company-ghci shm)
:bind (:map haskell-mode-map
- ("[f8]". haskell-navigate-imports)
+ ("C-c C-p". haskell-navigate-imports)
("C-c C-c" . haskell-compile)
("C-c C-z" . haskell-interactive-switch)
("C-c C-l" . haskell-process-load-file)
@@ -32,30 +22,19 @@
(haskell-mode . (lambda ()
(subword-mode 1)
(aggressive-indent-mode -1)
- (require 'shm)
- (require 'shm-case-split)
- (require 'ghc)
- (ghc-init)
- (structured-haskell-mode)
- ;; (haskell-indentation-mode)
+ (haskell-indentation-mode)
(interactive-haskell-mode)
(turn-on-haskell-doc-mode)
(turn-on-haskell-decl-scan)
- (add-to-list 'company-backends 'company-ghc)
- (add-to-list 'company-backends 'company-ghci)
- ;; (turn-on-haskell-unicode-input-method)
- ;; (haskell-mode-stylish-buffer)
- )))
+ (lsp)
+ (haskell-mode-stylish-buffer))))
:config
(setq haskell-doc-show-global-types t
haskell-doc-show-prelude t
haskell-doc-show-user-defined t
haskell-doc-show-reserved t
haskell-interactive-mode-eval-pretty t
- haskell-process-type 'cabal-repl
- company-ghc-show-info t
- company-ghc-autoscan t
- company-ghc-show-module t
+ haskell-process-type 'auto
haskell-stylish-on-save t
haskell-process-use-presentation-mode t
haskell-process-suggest-imports t