]> git.rkrishnan.org Git - .emacs.d.git/commitdiff
go mode, gofmt save hook
authorRamakrishnan Muthukrishnan <rama.krishnan@concur.com>
Mon, 16 Mar 2015 16:10:53 +0000 (21:40 +0530)
committerRamakrishnan Muthukrishnan <rama.krishnan@concur.com>
Mon, 16 Mar 2015 16:10:53 +0000 (21:40 +0530)
init.el

diff --git a/init.el b/init.el
index be9b90bf7de0d77c3a03c46141b81008fefc3e5a..8a4d472187ee6e6eec4aa36e6ab52a74cc7b57e6 100644 (file)
--- a/init.el
+++ b/init.el
@@ -38,7 +38,7 @@
   (package-refresh-contents))
 
 ;; make sure my list of packages are installed
-(setq package-list '(rust-mode haskell-mode clojure-mode ghc restclient tangotango-theme cider))
+(setq package-list '(go-mode rust-mode haskell-mode clojure-mode ghc restclient tangotango-theme cider))
 
 ; install the missing packages
 (dolist (package package-list)
 (defun my-haskell-mode-hook ()
    (local-set-key "\C-cl" 'hs-lint))
 (add-hook 'haskell-mode-hook 'my-haskell-mode-hook)
+
+;; gofmt
+(add-hook 'before-save-hook #'gofmt-before-save)