General cleanup

This commit is contained in:
Henrik Lissner 2016-04-19 02:08:48 -04:00
parent 0a4f4094b5
commit d506d8690e
12 changed files with 24 additions and 48 deletions

1
Cask
View file

@ -65,7 +65,6 @@
(depends-on "rotate-text" :git "https://github.com/debug-ito/rotate-text.el")
(depends-on "smart-forward")
(depends-on "smartparens")
(depends-on "vimrc-mode")
(depends-on "json-mode")
(depends-on "toml-mode")

View file

@ -251,14 +251,7 @@ Examples:
`(progn ,@(apply #'nconc (delete nil (delete (list nil) forms)))))))
;; Hooks ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defun narf|enable-comment-hard-wrap ()
(set (make-local-variable 'comment-auto-fill-only-comments) t)
(turn-on-auto-fill))
(defun narf|enable-hard-wrap ()
(turn-on-auto-fill))
;;
(defun narf|update-scratch-buffer-cwd (&optional dir) ; see core-editor.el
"Make sure scratch buffer is always 'in a project.'"
(let ((dir (or dir (narf/project-root))))

View file

@ -57,7 +57,6 @@
(message-mode . normal)
(debugger-mode . normal)
(profile-report-mode . emacs)
(Info-mode . emacs)
(view-mode . emacs)
(comint-mode . emacs)

View file

@ -7,6 +7,7 @@
;; Removed checks on idle/change for snappiness
flycheck-check-syntax-automatically '(save mode-enabled)
flycheck-disabled-checkers '(emacs-lisp emacs-lisp-checkdoc make))
:config
(require 'flycheck-package)
(flycheck-package-setup)

View file

@ -8,6 +8,7 @@
helm-quick-update t
helm-reuse-last-window-split-state t
;; Speedier without fuzzy matching
helm-mode-fuzzy-match nil
helm-buffers-fuzzy-matching nil
helm-apropos-fuzzy-match nil
@ -17,7 +18,6 @@
helm-display-header-line nil
helm-ff-auto-update-initial-value nil
helm-ff-skip-boring-files t
helm-find-files-doc-header nil
helm-move-to-line-cycle-in-source t
@ -129,7 +129,7 @@
helm-swoop-speed-or-color t
helm-swoop-pre-input-function (lambda () "")))
(use-package helm-describe-modes :defer t)
(use-package helm-describe-modes :commands helm-describe-modes)
(use-package helm-ring :commands helm-show-kill-ring)
(use-package helm-semantic :commands helm-semantic-or-imenu)
(use-package helm-elisp :commands helm-apropos)

View file

@ -23,16 +23,14 @@
("*evil-registers*" :align below :size 0.3)
("*quickrun*" :align below :size 10)
("*nosetests*" :align below :size 0.4 :noselect t)
("*eval*" :align below :size 12)
("*esup*" :align below :size 30 :noselect t)
("*ert*" :align below :size 20 :noselect t)
;; vcs
("^\\*git-gutter.+\\*$" :regexp t :align below :size 0.4 :noselect t)
("*vc-diff*" :align below :size 0.4 :noselect t)
("*vc-change-log*" :align below :select t)
(vc-annotate-mode :same t)
;; Util
("*Apropos*" :align below :size 0.3)
("*minor-modes*" :align below :size 0.5 :noselect t)
@ -56,7 +54,9 @@
(debugger-mode :align below :size 0.25 :noselect t)
(compilation-mode :noselect t)
;; REPLs
;; Custom + REPLs
("*eval*" :align below :size 12)
("^\\*narf.+\\*$" :regexp t :align below :size 12 :noselect t)
((:custom (lambda (b &rest _)
(when (featurep 'repl-toggle)
(when (string-prefix-p "*" (buffer-name (get-buffer b)))
@ -167,11 +167,7 @@
(defun narf|quickrun-hook ()
(narf|hide-mode-line))
(add-hook 'quickrun-after-run-hook 'narf|quickrun-after-run)
(add-hook 'quickrun/mode-hook 'narf|quickrun-hook))
(after! repl-toggle
(map! :map repl-toggle-mode-map
"ESC ESC" 'narf/popup-close))
(add-hook 'quickrun/mode-hook 'narf|hide-mode-line))
(add-hook! org-load
;; This ensures org-src-edit yields control of its buffer to shackle.

View file

@ -118,7 +118,7 @@
(add-hook 'evil-visual-state-exit-hook 'narf|hl-line-on)
;; Hide modeline in help windows
(defun narf|hide-mode-line ()
(defun narf|hide-mode-line (&rest _)
(setq mode-line-format nil))
(add-hook 'help-mode-hook 'narf|hide-mode-line)

View file

@ -1,12 +1,6 @@
;;; defuns-flycheck.el
;; for ../core-flycheck.el
;;;###autoload
(defun narf|flycheck-enable-maybe ()
(unless (or (bound-and-true-p org-src-mode)
(eq major-mode 'org-mode))
(flycheck-mode +1)))
;;;###autoload
(defun narf*flycheck-buffer ()
(when (bound-and-true-p flycheck-mode)

View file

@ -1,9 +1,5 @@
;;; defuns-popups.el
(defun narf*popup-add (&rest _)
(add-to-list 'narf-popup-windows (get-buffer-window shackle-last-buffer)))
(advice-add 'shackle-display-buffer :after 'narf*popup-add)
(defun narf--popup-remove (window)
(setq narf-popup-windows (delete window narf-popup-windows)))

View file

@ -34,8 +34,7 @@ If ARG is nil this function calls `recompile', otherwise it calls
;;;; Code running ;;;;;;;;;;;;;;;;;;;;;;
;;;###autoload (autoload 'narf:eval-buffer "defuns-quickrun" nil t)
(evil-define-command narf:eval-buffer ()
:move-point nil
:repeat nil
:move-point nil :repeat nil
(interactive)
(cond ((eq major-mode 'emacs-lisp-mode)
(narf:eval-region (point-min) (point-max)))
@ -43,10 +42,10 @@ If ARG is nil this function calls `recompile', otherwise it calls
;;;###autoload (autoload 'narf:eval-region "defuns-quickrun" nil t)
(evil-define-operator narf:eval-region (beg end)
:move-point nil
:repeat nil
:move-point nil :repeat nil
(interactive "<r>")
(cond ((eq major-mode 'emacs-lisp-mode)
(require 'pp)
(let* ((pp-escape-newlines nil)
(out (s-trim (pp-to-string (eval (read (buffer-substring-no-properties beg end))))))
(lines (length (s-lines out))))

16
init.el
View file

@ -66,7 +66,7 @@
;; Environments
module-apple ; Applescript, Swift, Launchbar, iOS, wallet syphons, etc.
module-cc ; c/c++/obj-c madness
module-cc ; C/C++/obj-c madness
module-crystal ; ruby at the speed of c
module-csharp ; unity, .NET, and mono shenanigans
module-go ; the hipster dialect
@ -90,16 +90,14 @@
;; Organizational/Notes
;;module-org ; for organized fearless leader
;;module-org-crm ; to keep tabs on my victims
;;module-org-notebook ; #modernizeOrgMode2016
;; Extra Tools
module-tmux ; closing the rift between GUI & terminal
module-demo ; allow me to demonstrate...
module-ansible ;
;;module-write ; for writing papers and fiction in Emacs
;; Key bindings & ex commands
;; Extra libraries
extra-tmux ; closing the rift between GUI & terminal
extra-demo ; allow me to demonstrate...
extra-ansible ;
;; Customization
my-bindings
my-commands
))

View file

@ -76,6 +76,7 @@
(1 font-lock-keyword-face)
(2 font-lock-function-name-face))))
;;
(use-package slime :defer t
:config (setq inferior-lisp-program "clisp"))