]> git.eshelyaron.com Git - emacs.git/commitdiff
Much less noisy mode line
authorJoão Távora <joaotavora@gmail.com>
Sat, 5 Oct 2019 11:32:23 +0000 (12:32 +0100)
committerJoão Távora <joaotavora@gmail.com>
Sat, 5 Oct 2019 11:32:23 +0000 (12:32 +0100)
* eglot.el (eglot--mode-line-format): Simplify.

GitHub-reference: fix https://github.com/joaotavora/eglot/issues/236

lisp/progmodes/eglot.el

index cfcfaa7d68aa604a342053062db4b92fb5ece2c0..0a9da05b1c6fc7285f68190a71fc51c1535590d9 100644 (file)
@@ -1314,7 +1314,7 @@ Uses THING, FACE, DEFS and PREPEND."
                (nick (and server (eglot--project-nickname server)))
                (pending (and server (hash-table-count
                                      (jsonrpc--request-continuations server))))
-               (`(,_id ,doing ,done-p ,detail) (and server (eglot--spinner server)))
+               (`(,_id ,doing ,done-p ,_detail) (and server (eglot--spinner server)))
                (last-error (and server (jsonrpc-last-error server))))
     (append
      `(,(eglot--mode-line-props "eglot" 'eglot-mode-line nil))
@@ -1332,15 +1332,13 @@ Uses THING, FACE, DEFS and PREPEND."
                      (format "An error occured: %s\n" (plist-get last-error
                                                                  :message)))))
          ,@(when (and doing (not done-p))
-             `("/" ,(eglot--mode-line-props
-                     (format "%s%s" doing
-                             (if detail (format ":%s" detail) ""))
-                     'compilation-mode-line-run '())))
+             `("/" ,(eglot--mode-line-props doing
+                                            'compilation-mode-line-run '())))
          ,@(when (cl-plusp pending)
              `("/" ,(eglot--mode-line-props
-                     (format "%d outstanding requests" pending) 'warning
+                     (format "%d" pending) 'warning
                      '((mouse-3 eglot-forget-pending-continuations
-                                "fahgettaboudit"))))))))))
+                                "forget pending continuations"))))))))))
 
 (add-to-list 'mode-line-misc-info
              `(eglot--managed-mode (" [" eglot--mode-line-format "] ")))