diff options
author | Bozhidar Batsov <bozhidar@batsov.com> | 2016-10-07 09:45:00 +0300 |
---|---|---|
committer | Bozhidar Batsov <bozhidar@batsov.com> | 2016-10-07 09:45:00 +0300 |
commit | 360daba09dc32d9f6208fac105285f5c8f3aed6c (patch) | |
tree | 475ec4852ace62498b5aa0ae16f79599198e17b4 /nrepl-client.el | |
parent | 415108cfe1ebf5091ba0f4247a178ba01692f680 (diff) |
[#1758] Add a new command nrepl-toggle-message-logging
Diffstat (limited to 'nrepl-client.el')
-rw-r--r-- | nrepl-client.el | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/nrepl-client.el b/nrepl-client.el index c2247b78..0fc2cb16 100644 --- a/nrepl-client.el +++ b/nrepl-client.el @@ -1103,6 +1103,16 @@ The message is logged to a buffer described by (set-window-point win (point-max))) (setq buffer-read-only t)))) +(defun nrepl-toggle-message-logging () + "Toggle the value of `nrepl-log-messages' between nil and t. + +This in effect enables or disables the logging of nREPL messages." + (interactive) + (setq nrepl-log-messages (not nrepl-log-messages)) + (if nrepl-log-messages + (message "nREPL message logging enabled") + (message "nREPL message logging disabled"))) + (defcustom nrepl-message-colors '("red" "brown" "coral" "orange" "green" "deep sky blue" "blue" "dark violet") "Colors used in `nrepl-messages-buffer'." |