From 67c2168998c829c8739a0a4f73ab9d6117d07f0a Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Sat, 16 Feb 2019 14:10:22 -0800 Subject: [emacs] Split configuration in multiple files. This is actually an easier thing to maintain. --- emacs.d/custom/fcuny-go.el | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 emacs.d/custom/fcuny-go.el (limited to 'emacs.d/custom/fcuny-go.el') diff --git a/emacs.d/custom/fcuny-go.el b/emacs.d/custom/fcuny-go.el new file mode 100644 index 0000000..3926c9e --- /dev/null +++ b/emacs.d/custom/fcuny-go.el @@ -0,0 +1,13 @@ +(use-package go-mode + :ensure t + :after (exec-path-from-shell) + :hook (go-mode . fcuny/go-mode-setup) + :init + (defun fcuny/go-mode-setup () + (setq tab-width 4) + (add-hook 'before-save-hook 'gofmt-before-save)) + :config + (when (memq window-system '(mac ns)) + (exec-path-from-shell-copy-env "GOPATH"))) + +(provide 'fcuny-go) -- cgit 1.4.1