X-Git-Url: https://thelambdalab.xyz/gitweb/index.cgi?p=lurk.git;a=blobdiff_plain;f=lurk.el;fp=lurk.el;h=bae68ceff07254c34003990fae00adff7cc8db08;hp=bd1e416ac95aa8610cfc4824238f53b47aa3ebac;hb=1ad31877ce86f4e5f9336360e875e33d208a801f;hpb=d9a9192dde02a1d7b79771bfbc6e6cfe3a7fe1a9 diff --git a/lurk.el b/lurk.el index bd1e416..bae68ce 100644 --- a/lurk.el +++ b/lurk.el @@ -826,6 +826,7 @@ in which case they match anything.") '(("DEBUG" "Toggle debug mode on/off." lurk-command-debug lurk-boolean-completions) ("HEADER" "Toggle display of header." lurk-command-header lurk-boolean-completions) ("CONNECT" "Connect to an IRC network." lurk-command-connect lurk-network-completions) + ("NETWORKS" "List known IRC networks." lurk-command-networks) ("TOPIC" "Set topic for current channel." lurk-command-topic) ("ME" "Display action." lurk-command-me) ("VERSION" "Request version of another user's client via CTCP." lurk-command-version) @@ -893,6 +894,15 @@ in which case they match anything.") (lurk-connect network)) (lurk-display-notice nil "Usage: /connect "))) +(defun lurk-command-networks (params) + (lurk-display-notice nil "Currently-known networks:") + (dolist (row lurk-networks) + (seq-let (network server port &rest others) row + (lurk-display-notice nil "\t" network + " [" server + " " (number-to-string port) "]"))) + (lurk-display-notice nil "(Modify the `lurk-networks' variable to add more.)")) + (defun lurk-command-quit (params) (let ((quit-msg (if params (string-join params " ") nil))) (lurk-send-msg (lurk-msg nil nil "QUIT" quit-msg)))) @@ -1075,7 +1085,6 @@ in which case they match anything.") (lurk-enter-string line)))) - ;;; Mode ;;