emacs: use golines to format go files
Alan Pearce alan@alanpearce.eu
Sat, 11 May 2024 15:04:27 +0200
1 files changed, 2 insertions(+), 1 deletions(-)
jump to
M user/emacs/init.el → user/emacs/init.el
@@ -1111,11 +1111,12 @@ (setf (alist-get 'shfmt apheleia-formatters) '("shfmt")) (setq apheleia-formatters (append apheleia-formatters '((nixpkgs-fmt "nixpkgs-fmt") + (golines "golines") (prettier-gotmpl ("prettier" "--stdin-filepath" filepath "--parser=go-template" (apheleia-formatters-js-indent "--use-tabs" "--tab-width")))))) (setf (alist-get 'go-ts-mode apheleia-mode-alist) - '(goimports)) + '(golines)) (setq apheleia-mode-alist (append apheleia-mode-alist '((nix-ts-mode . nixpkgs-fmt) (nix-mode . nixpkgs-fmt) (go-ts-mode . prettier-gotmpl))))