From 1bc888574a3f10e1fecceb2e9d8e4cc031d230e4 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Sun, 25 Oct 2015 15:59:10 -0700 Subject: [PATCH] goimport as gofmt command --- dotfiles/emacs.d/init.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index 3c781353..fbd189f5 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -2177,7 +2177,8 @@ window is active in the perspective." (imenu-default-create-index-function)))) (set (make-local-variable 'company-backends) '(company-go))) (add-hook 'go-mode-hook 'imalison:go-mode-hook) - (add-hook 'before-save-hook 'gofmt-before-save))) + (setq gofmt-command "goimports") + (add-hook 'before-save-hook 'gofmt-before-save t))) (use-package rust-mode :mode (("\\.rs\\'" . rust-mode)))