From: Ramakrishnan Muthukrishnan Date: Wed, 20 Jul 2016 05:40:54 +0000 (+0530) Subject: bunch of additions, racer for rust, inconsolataGo X-Git-Url: https://git.rkrishnan.org/pf/content/en/service/simplejson/configuration.txt?a=commitdiff_plain;h=dca62441c84260ff512bf3d3d375fdbc4d5daa1b;p=.emacs.d.git bunch of additions, racer for rust, inconsolataGo --- diff --git a/init.el b/init.el index 0720899..2fe2b23 100644 --- a/init.el +++ b/init.el @@ -19,6 +19,7 @@ ;; font ;; (set-default-font "Inconsolata-12") +(set-default-font "InconsolataGo-12") ;; Don't let Emacs hurt your ears (setq visible-bell t) @@ -53,8 +54,10 @@ (erc-autojoin-mode t) (setq erc-autojoin-channels-alist - '((".*\\.freenode.net" "#tahoe-lafs") ;; #inferno "#plan9chan" "#cat-v") - (".*\\.oftc.net" "#LeastAuthority"))) + '((".*\\.freenode.net" "#haskell-beginners" "#tahoe-lafs") + (".*\\.oftc.net" "#LeastAuthority") +;; (".*\\.mozilla.org" "#rust-beginners") + )) ;; check channels (erc-track-mode t) @@ -67,7 +70,7 @@ "Connect to IRC." (interactive) (when (y-or-n-p "Do you want to start IRC? ") - ;;(erc-tls :server "irc.mozilla.org" :port 6697 :nick "rkrishnan" :full-name "Ramakrishnan Muthukrishnan") + ;; (erc-tls :server "irc.mozilla.org" :port 6697 :nick "rkrishnan" :full-name "Ramakrishnan Muthukrishnan") (erc-tls :server "irc.freenode.net" :port 6697 :nick "rkrishnan" :full-name "Ramakrishnan Muthukrishnan") (erc-tls :server "irc.oftc.net" :port 6697 :nick "rkrishnan" :full-name "Ramakrishnan Muthukrishnan"))) @@ -131,6 +134,7 @@ (require 'hs-lint) (defun my-haskell-mode-hook () (local-set-key "\C-cl" 'hs-lint)) + (add-hook 'haskell-mode-hook 'my-haskell-mode-hook) ;; gofmt @@ -192,6 +196,24 @@ ;; company mode for auto completion (add-hook 'after-init-hook 'global-company-mode) +;; Reduce the time after which the company auto completion popup opens +(setq company-idle-delay 0.2) + +;; Reduce the number of characters before company kicks in +(setq company-minimum-prefix-length 1) + +;; Set path to racer binary +(setq racer-cmd "/home/ram/.cargo/bin/racer") + +(add-hook 'rust-mode-hook + '(lambda () + (racer-activate) + (racer-turn-on-eldoc) + (add-hook 'flycheck-mode-hook #'flycheck-rust-setup) + (set (make-local-variable 'company-backends) '(company-racer)) + (local-set-key (kbd "M-.") #'racer-find-definition) + (local-set-key (kbd "TAB") #'racer-complete-or-indent))) + ;; highlight todo ;; (add-hook 'prog-mode-hook 'highlight-todos)