diff options
| author | Eli Zaretskii | 2017-05-12 11:38:04 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2017-05-12 11:38:04 +0300 |
| commit | 27cef30c2bff44a76cf5c3da51de625f4de8112d (patch) | |
| tree | 4b0d5e92e225bc994f0e40927e2a8dda381c9589 | |
| parent | a1b69815147b67f4ff7730d0b97b526c8eda2935 (diff) | |
| download | emacs-27cef30c2bff44a76cf5c3da51de625f4de8112d.tar.gz emacs-27cef30c2bff44a76cf5c3da51de625f4de8112d.zip | |
Improve doc strings in net-utils.el
* lisp/net/net-utils.el (ifconfig, iwconfig, netstat, arp)
(route, traceroute, nslookup, ftp, smbclient)
(smbclient-list-shares, finger, whois)
(network-connection-to-service, network-service-connection)
(network-connection-reconnect): Improve doc strings.
| -rw-r--r-- | lisp/net/net-utils.el | 39 |
1 files changed, 24 insertions, 15 deletions
diff --git a/lisp/net/net-utils.el b/lisp/net/net-utils.el index 6b38462ff3e..280c6674707 100644 --- a/lisp/net/net-utils.el +++ b/lisp/net/net-utils.el | |||
| @@ -424,7 +424,7 @@ This variable is only used if the variable | |||
| 424 | 424 | ||
| 425 | ;;;###autoload | 425 | ;;;###autoload |
| 426 | (defun ifconfig () | 426 | (defun ifconfig () |
| 427 | "Run ifconfig and display diagnostic output." | 427 | "Run `ifconfig-program' and display diagnostic output." |
| 428 | (interactive) | 428 | (interactive) |
| 429 | (net-utils-run-simple | 429 | (net-utils-run-simple |
| 430 | (format "*%s*" ifconfig-program) | 430 | (format "*%s*" ifconfig-program) |
| @@ -435,7 +435,7 @@ This variable is only used if the variable | |||
| 435 | 435 | ||
| 436 | ;;;###autoload | 436 | ;;;###autoload |
| 437 | (defun iwconfig () | 437 | (defun iwconfig () |
| 438 | "Run iwconfig and display diagnostic output." | 438 | "Run `iwconfig-program' and display diagnostic output." |
| 439 | (interactive) | 439 | (interactive) |
| 440 | (net-utils-run-simple | 440 | (net-utils-run-simple |
| 441 | (format "*%s*" iwconfig-program) | 441 | (format "*%s*" iwconfig-program) |
| @@ -444,7 +444,7 @@ This variable is only used if the variable | |||
| 444 | 444 | ||
| 445 | ;;;###autoload | 445 | ;;;###autoload |
| 446 | (defun netstat () | 446 | (defun netstat () |
| 447 | "Run netstat and display diagnostic output." | 447 | "Run `netstat-program' and display diagnostic output." |
| 448 | (interactive) | 448 | (interactive) |
| 449 | (net-utils-run-simple | 449 | (net-utils-run-simple |
| 450 | (format "*%s*" netstat-program) | 450 | (format "*%s*" netstat-program) |
| @@ -453,7 +453,7 @@ This variable is only used if the variable | |||
| 453 | 453 | ||
| 454 | ;;;###autoload | 454 | ;;;###autoload |
| 455 | (defun arp () | 455 | (defun arp () |
| 456 | "Run arp and display diagnostic output." | 456 | "Run `arp-program' and display diagnostic output." |
| 457 | (interactive) | 457 | (interactive) |
| 458 | (net-utils-run-simple | 458 | (net-utils-run-simple |
| 459 | (format "*%s*" arp-program) | 459 | (format "*%s*" arp-program) |
| @@ -462,7 +462,7 @@ This variable is only used if the variable | |||
| 462 | 462 | ||
| 463 | ;;;###autoload | 463 | ;;;###autoload |
| 464 | (defun route () | 464 | (defun route () |
| 465 | "Run route and display diagnostic output." | 465 | "Run `route-program' and display diagnostic output." |
| 466 | (interactive) | 466 | (interactive) |
| 467 | (net-utils-run-simple | 467 | (net-utils-run-simple |
| 468 | (format "*%s*" route-program) | 468 | (format "*%s*" route-program) |
| @@ -475,7 +475,7 @@ This variable is only used if the variable | |||
| 475 | 475 | ||
| 476 | ;;;###autoload | 476 | ;;;###autoload |
| 477 | (defun traceroute (target) | 477 | (defun traceroute (target) |
| 478 | "Run traceroute program for TARGET." | 478 | "Run `traceroute-program' for TARGET." |
| 479 | (interactive "sTarget: ") | 479 | (interactive "sTarget: ") |
| 480 | (let ((options | 480 | (let ((options |
| 481 | (if traceroute-program-options | 481 | (if traceroute-program-options |
| @@ -537,7 +537,7 @@ This command uses `nslookup-program' for looking up the DNS information." | |||
| 537 | 537 | ||
| 538 | ;;;###autoload | 538 | ;;;###autoload |
| 539 | (defun nslookup () | 539 | (defun nslookup () |
| 540 | "Run nslookup program." | 540 | "Run `nslookup-program'." |
| 541 | (interactive) | 541 | (interactive) |
| 542 | (switch-to-buffer (make-comint "nslookup" nslookup-program)) | 542 | (switch-to-buffer (make-comint "nslookup" nslookup-program)) |
| 543 | (nslookup-mode)) | 543 | (nslookup-mode)) |
| @@ -612,7 +612,7 @@ This command uses `dig-program' for looking up the DNS information." | |||
| 612 | ;; This is a lot less than ange-ftp, but much simpler. | 612 | ;; This is a lot less than ange-ftp, but much simpler. |
| 613 | ;;;###autoload | 613 | ;;;###autoload |
| 614 | (defun ftp (host) | 614 | (defun ftp (host) |
| 615 | "Run `ftp program." | 615 | "Run `ftp-program' to connect to HOST." |
| 616 | (interactive | 616 | (interactive |
| 617 | (list | 617 | (list |
| 618 | (read-from-minibuffer | 618 | (read-from-minibuffer |
| @@ -648,7 +648,9 @@ This command uses `dig-program' for looking up the DNS information." | |||
| 648 | nil t))) | 648 | nil t))) |
| 649 | 649 | ||
| 650 | (defun smbclient (host service) | 650 | (defun smbclient (host service) |
| 651 | "Connect to SERVICE on HOST via SMB." | 651 | "Connect to SERVICE on HOST via SMB. |
| 652 | |||
| 653 | This command uses `smbclient-program' to connect to HOST." | ||
| 652 | (interactive | 654 | (interactive |
| 653 | (list | 655 | (list |
| 654 | (read-from-minibuffer | 656 | (read-from-minibuffer |
| @@ -666,7 +668,8 @@ This command uses `dig-program' for looking up the DNS information." | |||
| 666 | (pop-to-buffer buf))) | 668 | (pop-to-buffer buf))) |
| 667 | 669 | ||
| 668 | (defun smbclient-list-shares (host) | 670 | (defun smbclient-list-shares (host) |
| 669 | "List services on HOST." | 671 | "List services on HOST. |
| 672 | This command uses `smbclient-program' to connect to HOST." | ||
| 670 | (interactive | 673 | (interactive |
| 671 | (list | 674 | (list |
| 672 | (read-from-minibuffer | 675 | (read-from-minibuffer |
| @@ -761,7 +764,9 @@ queries of the form USER@HOST, and wants a query containing USER only." | |||
| 761 | ;; Finger protocol | 764 | ;; Finger protocol |
| 762 | ;;;###autoload | 765 | ;;;###autoload |
| 763 | (defun finger (user host) | 766 | (defun finger (user host) |
| 764 | "Finger USER on HOST." | 767 | "Finger USER on HOST. |
| 768 | This command uses `finger-X.500-host-regexps' | ||
| 769 | and `network-connection-service-alist', which see." | ||
| 765 | ;; One of those great interactive statements that's actually | 770 | ;; One of those great interactive statements that's actually |
| 766 | ;; longer than the function call! The idea is that if the user | 771 | ;; longer than the function call! The idea is that if the user |
| 767 | ;; uses a string like "pbreton@cs.umb.edu", we won't ask for the | 772 | ;; uses a string like "pbreton@cs.umb.edu", we won't ask for the |
| @@ -855,7 +860,8 @@ then the server named by `whois-server-name' is used." | |||
| 855 | (defun whois (arg search-string) | 860 | (defun whois (arg search-string) |
| 856 | "Send SEARCH-STRING to server defined by the `whois-server-name' variable. | 861 | "Send SEARCH-STRING to server defined by the `whois-server-name' variable. |
| 857 | If `whois-guess-server' is non-nil, then try to deduce the correct server | 862 | If `whois-guess-server' is non-nil, then try to deduce the correct server |
| 858 | from SEARCH-STRING. With argument, prompt for whois server." | 863 | from SEARCH-STRING. With argument, prompt for whois server. |
| 864 | The port is deduced from `network-connection-service-alist'." | ||
| 859 | (interactive "P\nsWhois: ") | 865 | (interactive "P\nsWhois: ") |
| 860 | (let* ((whois-apropos-host (if whois-guess-server | 866 | (let* ((whois-apropos-host (if whois-guess-server |
| 861 | (rassoc (whois-get-tld search-string) | 867 | (rassoc (whois-get-tld search-string) |
| @@ -903,7 +909,8 @@ from SEARCH-STRING. With argument, prompt for whois server." | |||
| 903 | 909 | ||
| 904 | ;;;###autoload | 910 | ;;;###autoload |
| 905 | (defun network-connection-to-service (host service) | 911 | (defun network-connection-to-service (host service) |
| 906 | "Open a network connection to SERVICE on HOST." | 912 | "Open a network connection to SERVICE on HOST. |
| 913 | This command uses `network-connection-service-alist', which see." | ||
| 907 | (interactive | 914 | (interactive |
| 908 | (list | 915 | (list |
| 909 | (read-from-minibuffer "Host: " (net-utils-machine-at-point)) | 916 | (read-from-minibuffer "Host: " (net-utils-machine-at-point)) |
| @@ -924,7 +931,8 @@ from SEARCH-STRING. With argument, prompt for whois server." | |||
| 924 | (network-service-connection host (number-to-string port))) | 931 | (network-service-connection host (number-to-string port))) |
| 925 | 932 | ||
| 926 | (defun network-service-connection (host service) | 933 | (defun network-service-connection (host service) |
| 927 | "Open a network connection to SERVICE on HOST." | 934 | "Open a network connection to SERVICE on HOST. |
| 935 | The port to use is determined from `network-connection-service-alist'." | ||
| 928 | (let* ((process-name (concat "Network Connection [" host " " service "]")) | 936 | (let* ((process-name (concat "Network Connection [" host " " service "]")) |
| 929 | (portnum (string-to-number service)) | 937 | (portnum (string-to-number service)) |
| 930 | (buf (get-buffer-create (concat "*" process-name "*")))) | 938 | (buf (get-buffer-create (concat "*" process-name "*")))) |
| @@ -940,7 +948,8 @@ from SEARCH-STRING. With argument, prompt for whois server." | |||
| 940 | (defvar comint-input-ring) | 948 | (defvar comint-input-ring) |
| 941 | 949 | ||
| 942 | (defun network-connection-reconnect () | 950 | (defun network-connection-reconnect () |
| 943 | "Reconnect a network connection, preserving the old input ring." | 951 | "Reconnect a network connection, preserving the old input ring. |
| 952 | This command uses `network-connection-service-alist', which see." | ||
| 944 | (interactive) | 953 | (interactive) |
| 945 | (let ((proc (get-buffer-process (current-buffer))) | 954 | (let ((proc (get-buffer-process (current-buffer))) |
| 946 | (old-comint-input-ring comint-input-ring) | 955 | (old-comint-input-ring comint-input-ring) |