summary refs log tree commit diff stats
path: root/user
diff options
context:
space:
mode:
Diffstat (limited to 'user')
-rw-r--r--user/emacs/init.el24
-rw-r--r--user/settings/emacs.nix3
2 files changed, 15 insertions, 12 deletions
diff --git a/user/emacs/init.el b/user/emacs/init.el
index b05e2a2e..d1d783c1 100644
--- a/user/emacs/init.el
+++ b/user/emacs/init.el
@@ -935,16 +935,20 @@ _p_rev       _u_pper              _=_: upper/lower       _r_esolve
 
 ;;;; Reformat on save
 
-(use-package prettier-js
-  :ghook ('(javascript-mode-hook typescript-mode-hook) #'prettier-js-mode t)
-  :config (progn
-            (setq prettier-js-show-errors 'echo)))
-
-(use-package sqlformat
-  :ghook ('sql-mode-hook #'sqlformat-on-save-mode)
-  :config (progn
-            (setq sqlformat-command 'pgformatter
-                  sqlformat-args '("-s2"))))
+(use-package format-all
+  :ghook ('(css-mode-hook
+            dockerfile-mode-hook
+            emacs-lisp-mode-hook
+            javascript-mode-hook
+            json-mode-hook
+            markdown-mode-hook
+            scss-mode-hook
+            sgml-mode-hook
+            sh-mode-hook
+            sql-mode-hook
+            toml-mode-hook
+            typescript-mode-hook
+            yaml-mode-hook)))
 
 ;;; E-mail
 
diff --git a/user/settings/emacs.nix b/user/settings/emacs.nix
index e53e6aa4..4d0d20d7 100644
--- a/user/settings/emacs.nix
+++ b/user/settings/emacs.nix
@@ -119,6 +119,7 @@ in
       evil-surround
       eyebrowse
       feature-mode
+      format-all
       fish-completion
       flycheck
       general
@@ -157,7 +158,6 @@ in
       paredit
       php-mode
       posframe
-      prettier-js
       projectile
       projectile-ripgrep
       quickrun
@@ -167,7 +167,6 @@ in
       rjsx-mode
       scss-mode
       spacemacs-theme
-      sqlformat
       swiper
       tide
       toml-mode