From 398cd680ad737939397324954d263c9f8cbeb0d6 Mon Sep 17 00:00:00 2001 From: John Doty Date: Sat, 17 Dec 2016 07:16:40 -0800 Subject: [PATCH 1/4] Prefer UTF8; stops prompting on Windows when I refresh packages. --- .emacs.d/core.el | 1 + 1 file changed, 1 insertion(+) diff --git a/.emacs.d/core.el b/.emacs.d/core.el index 9e4b059..ca5647a 100644 --- a/.emacs.d/core.el +++ b/.emacs.d/core.el @@ -84,6 +84,7 @@ (require 'uniquify) (require 'ansi-color) (require 'recentf) +(prefer-coding-system 'utf-8) ;; ================================================================= ;; Packages From 4cb284121c7079444e7fc44c54123a33ac8f6ba8 Mon Sep 17 00:00:00 2001 From: John Doty Date: Sat, 17 Dec 2016 07:17:12 -0800 Subject: [PATCH 2/4] Remove marmalade; it never works properly. --- .emacs.d/core.el | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.emacs.d/core.el b/.emacs.d/core.el index ca5647a..a8b2f87 100644 --- a/.emacs.d/core.el +++ b/.emacs.d/core.el @@ -92,8 +92,8 @@ (setq package-archives '(("gnu" . "http://elpa.gnu.org/packages/") ("org" . "http://orgmode.org/elpa/") - ("melpa" . "http://melpa.org/packages/") - ("marmalade" . "https://marmalade-repo.org/packages/"))) + ("melpa" . "http://stable.melpa.org/packages/") + )) (when (< emacs-major-version 24) ;; For important compatibility libraries like cl-lib (add-to-list 'package-archives '("gnu" . "http://elpa.gnu.org/packages/"))) @@ -103,9 +103,6 @@ (list 'auto-complete ; complete as you type with overlays 'auto-complete-nxml ; Auto-complete for nxml - 'color-theme ; Color themes... - 'color-theme-monokai ; ...Monokai - 'color-theme-solarized ; ...Solarized 'csharp-mode ; C# mode 'exec-path-from-shell ; Fix path on MacOS 'flycheck ; Checking From e963d456b6b1a3936174fada2e7d38eb891fe15b Mon Sep 17 00:00:00 2001 From: John Doty Date: Sat, 17 Dec 2016 07:17:38 -0800 Subject: [PATCH 3/4] Support Input Mono on Windows (Don't know why it's named differently.) --- .emacs.d/core.el | 1 + 1 file changed, 1 insertion(+) diff --git a/.emacs.d/core.el b/.emacs.d/core.el index a8b2f87..b0d86aa 100644 --- a/.emacs.d/core.el +++ b/.emacs.d/core.el @@ -194,6 +194,7 @@ (setq my-font-choice (font-candidate "Input Mono-12:weight=light" + "InputMono Light-12:light" "Consolas-10" "Inconsolata-11")) From e9aa8f681280f9c3915fd8bda8c2429f03d0ace7 Mon Sep 17 00:00:00 2001 From: John Doty Date: Sun, 18 Dec 2016 18:53:26 -0800 Subject: [PATCH 4/4] Stuff --- .emacs.d/core.el | 29 +++++++++++++---------------- .emacs.d/custom.el | 4 +++- 2 files changed, 16 insertions(+), 17 deletions(-) diff --git a/.emacs.d/core.el b/.emacs.d/core.el index b0d86aa..f900dc7 100644 --- a/.emacs.d/core.el +++ b/.emacs.d/core.el @@ -228,17 +228,18 @@ ;; ================================================================= ;; FUN WITH KEY BINDINGS! YAAAAYYY!!! ;; ================================================================= -(global-set-key (read-kbd-macro "M-g") 'goto-line) -(global-set-key (read-kbd-macro "C-q") 'copy-region-as-kill) -(global-set-key (read-kbd-macro "C-w") 'kill-region) +(global-set-key (read-kbd-macro "") 'end-of-buffer) +(global-set-key (read-kbd-macro "") 'beginning-of-buffer) -(global-set-key (read-kbd-macro "") 'beginning-of-buffer) -(global-set-key (read-kbd-macro "") 'end-of-buffer) +(global-set-key (read-kbd-macro "C-/") 'comment-or-uncomment-region) +(global-set-key (read-kbd-macro "C-c TAB") 'indent-buffer) +(global-set-key (read-kbd-macro "C-q") 'copy-region-as-kill) +(global-set-key (read-kbd-macro "C-w") 'kill-region) +(global-set-key (read-kbd-macro "C-x f") 'font-lock-fontify-buffer) -(global-set-key (read-kbd-macro "M-1") 'new-frame) -(global-set-key (read-kbd-macro "M-3") 'delete-frame) - -(global-set-key (read-kbd-macro "C-x f") 'font-lock-fontify-buffer) +(global-set-key (read-kbd-macro "M-1") 'new-frame) +(global-set-key (read-kbd-macro "M-3") 'delete-frame) +(global-set-key (read-kbd-macro "M-g") 'goto-line) ;; In addition, make sure various things are working properly with xterm-keys ;; on under tmux. (This has been the most reliable way to get putty to send @@ -264,7 +265,6 @@ (require 'filladapt) (setq-default filladapt-mode t) -;; We're going to stop doing ido and start doing helm, maybe? (require 'ido) ;; Cleanup all the whitespaces. @@ -278,6 +278,7 @@ ;; Text mode configuration. ;; ================================================================= (defun my-text-mode-hook () + "Doty's hook for text mode." (setq fill-column 70) (turn-on-auto-fill) (flyspell-mode)) @@ -448,8 +449,6 @@ (indent-region (point-min) (point-max)) (whitespace-cleanup)) -(global-set-key (read-kbd-macro "C-c TAB") 'indent-buffer) - ;; IDL (c-add-style "ms-idl" '("gnu" @@ -837,10 +836,8 @@ (add-hook 'comint-output-filter-functions 'comint-truncate-buffer) (add-hook 'shell-mode-hook 'buffer-disable-undo) -;; -;; Comment all the time -;; -(global-set-key (kbd "C-/") 'comment-or-uncomment-region) +;; ag +(global-set-key (kbd "M-p") 'ag-project-regexp) (provide 'core) ;;; core.el ends here diff --git a/.emacs.d/custom.el b/.emacs.d/custom.el index fc4d13f..7c2d977 100644 --- a/.emacs.d/custom.el +++ b/.emacs.d/custom.el @@ -3,6 +3,8 @@ ;; 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. + '(ag-arguments (quote ("--line-number" "--smart-case" "--column" "--"))) + '(ag-executable "rg") '(blink-matching-paren-dont-ignore-comments t) '(c-basic-offset 2) '(c-echo-syntactic-information-p t) @@ -37,7 +39,7 @@ '(org-odd-levels-only t) '(package-selected-packages (quote - (dockerfile-mode js2-mode ## web-mode ahg zencoding-mode tss switch-window python-mode paredit monky magit lua-mode go-mode go-autocomplete flycheck exec-path-from-shell csharp-mode color-theme-solarized color-theme-monokai auto-complete-nxml))) + (ag use-package flycheck dockerfile-mode js2-mode ## web-mode ahg zencoding-mode tss switch-window python-mode paredit monky magit lua-mode go-mode go-autocomplete exec-path-from-shell csharp-mode color-theme-solarized color-theme-monokai auto-complete-nxml))) '(rmail-mail-new-frame t) '(safe-local-variable-values (quote