[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/go-mode 50fb3b2 192/495: allow users to customize the gofm
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/go-mode 50fb3b2 192/495: allow users to customize the gofmt command |
Date: |
Sat, 7 Aug 2021 09:05:11 -0400 (EDT) |
branch: elpa/go-mode
commit 50fb3b26f603f011775173326a6468b700a2973a
Author: Sameer Ajmani <sameer@golang.org>
Commit: Dominik Honnef <dominikh@fork-bomb.org>
allow users to customize the gofmt command
---
go-mode.el | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/go-mode.el b/go-mode.el
index af5d6b3..556046c 100644
--- a/go-mode.el
+++ b/go-mode.el
@@ -170,6 +170,12 @@ customize this variable to point to the wrapper script."
:type 'string
:group 'go)
+(defcustom gofmt-command "gofmt"
+ "The 'gofmt' command. Some users may replace this with 'goimports'
+from https://github.com/bradfitz/goimports."
+ :type 'string
+ :group 'go)
+
(defface go-coverage-untracked
'((t (:foreground "#505050")))
"Coverage color of untracked code."
@@ -650,7 +656,7 @@ buffer."
;; We're using errbuf for the mixed stdout and stderr output. This
;; is not an issue because gofmt -w does not produce any stdout
;; output in case of success.
- (if (zerop (call-process "gofmt" nil errbuf nil "-w" tmpfile))
+ (if (zerop (call-process gofmt-command nil errbuf nil "-w" tmpfile))
(if (zerop (call-process-region (point-min) (point-max) "diff" nil
patchbuf nil "-n" "-" tmpfile))
(progn
(kill-buffer errbuf)
- [nongnu] elpa/go-mode 5fd1c63 156/495: document go-goto-opening-parenthesis, (continued)
- [nongnu] elpa/go-mode 5fd1c63 156/495: document go-goto-opening-parenthesis, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode f4d2977 158/495: add go-coverage to display coverage information, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode a5d5039 161/495: use go--goto-line where applicable, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 7ef7e56 163/495: correct docstrings of go-coverage-covered and go-coverage-uncovered, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 042f08c 169/495: if go-coverage is called in a coverage buffer, update it by using stored variables, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode eea3ccf 170/495: move some coverage code into own functions, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode fdb2132 179/495: no free variables, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 9617f0c 176/495: move actual parsing of coverage file into own function, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 1949b57 184/495: match unused imports where path and package name differ, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode ff30ae1 190/495: use (function) for function symbols, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 50fb3b2 192/495: allow users to customize the gofmt command,
ELPA Syncer <=
- [nongnu] elpa/go-mode 49c885d 188/495: (foo)(bar) is not a function call when there's a letter directly preceding it, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 83c4e32 185/495: fix typo, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode b4cbae5 193/495: minor cleanups, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 4a96be2 186/495: handle empty "import ()" in go-goto-imports, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 4055561 191/495: Don't break on emacsen that don't have declare-function macro, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode ad5e273 203/495: suggest flycheck as well as flymake and fix URL markup, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 26ca1fd 199/495: do not highlight built-in function if not followed by '(', ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 192c9e2 195/495: Use "point" argument instead of return value of point function, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 73ff68c 198/495: handle backslash in raw string in Emacs 23, ELPA Syncer, 2021/08/07
- [nongnu] elpa/go-mode 1071ac6 209/495: simplify godef--successful-p, ELPA Syncer, 2021/08/07