[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r103486: Add --quiet option for emacs
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r103486: Add --quiet option for emacsclient (bug#663) (tiny change) |
Date: |
Wed, 02 Mar 2011 23:00:23 -0800 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 103486
author: Drake Wilson <address@hidden>
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Wed 2011-03-02 23:00:23 -0800
message:
Add --quiet option for emacsclient (bug#663) (tiny change)
* lib-src/emacsclient.c (longopts): Add quiet.
(decode_options): Handle q/quiet.
(print_help_and_exit): Add q/quiet.
(main): Suppress some messages if quiet option is used.
* doc/emacs/misc.texi (emacsclient Options): Add q/quiet.
modified:
doc/emacs/ChangeLog
doc/emacs/misc.texi
lib-src/ChangeLog
lib-src/emacsclient.c
=== modified file 'doc/emacs/ChangeLog'
--- a/doc/emacs/ChangeLog 2011-03-02 08:53:23 +0000
+++ b/doc/emacs/ChangeLog 2011-03-03 07:00:23 +0000
@@ -1,3 +1,7 @@
+2011-03-03 Drake Wilson <address@hidden> (tiny change)
+
+ * misc.texi (emacsclient Options): Add q/quiet.
+
2011-03-02 Glenn Morris <address@hidden>
* mule.texi (Communication Coding) <x-select-request-type>:
=== modified file 'doc/emacs/misc.texi'
--- a/doc/emacs/misc.texi 2011-01-25 04:08:28 +0000
+++ b/doc/emacs/misc.texi 2011-03-03 07:00:23 +0000
@@ -1672,6 +1672,11 @@
edit the server buffers within Emacs, and they are @emph{not} killed
when you type @kbd{C-x #} in them.
address@hidden -q
address@hidden --quiet
+Do not let @command{emacsclient} display messages about waiting for
+Emacs or connecting to remote server sockets.
+
@item -s @var{server-name}
@itemx address@hidden
Connect to the Emacs server named @var{server-name}. The server name
=== modified file 'lib-src/ChangeLog'
--- a/lib-src/ChangeLog 2011-02-26 08:36:56 +0000
+++ b/lib-src/ChangeLog 2011-03-03 07:00:23 +0000
@@ -1,3 +1,10 @@
+2011-03-03 Drake Wilson <address@hidden> (tiny change)
+
+ * emacsclient.c (longopts): Add quiet.
+ (decode_options): Handle q/quiet.
+ (print_help_and_exit): Add q/quiet.
+ (main): Suppress some messages if quiet option is used.
+
2011-02-26 Eli Zaretskii <address@hidden>
* Makefile.in (fakemail${EXEEXT}): Depend on lib/ignore-value.h.
=== modified file 'lib-src/emacsclient.c'
--- a/lib-src/emacsclient.c 2011-02-26 07:44:38 +0000
+++ b/lib-src/emacsclient.c 2011-03-03 07:00:23 +0000
@@ -129,6 +129,9 @@
/* Nonzero means don't wait for a response from Emacs. --no-wait. */
int nowait = 0;
+/* Nonzero means don't print messages for successful operations. --quiet. */
+int quiet = 0;
+
/* Nonzero means args are expressions to be evaluated. --eval. */
int eval = 0;
@@ -164,6 +167,7 @@
struct option longopts[] =
{
{ "no-wait", no_argument, NULL, 'n' },
+ { "quiet", no_argument, NULL, 'q' },
{ "eval", no_argument, NULL, 'e' },
{ "help", no_argument, NULL, 'H' },
{ "version", no_argument, NULL, 'V' },
@@ -523,9 +527,9 @@
{
int opt = getopt_long_only (argc, argv,
#ifndef NO_SOCKETS_IN_FILE_SYSTEM
- "VHnea:s:f:d:tc",
+ "VHneqa:s:f:d:tc",
#else
- "VHnea:f:d:tc",
+ "VHneqa:f:d:tc",
#endif
longopts, 0);
@@ -569,6 +573,10 @@
eval = 1;
break;
+ case 'q':
+ quiet = 1;
+ break;
+
case 'V':
message (FALSE, "emacsclient %s\n", VERSION);
exit (EXIT_SUCCESS);
@@ -660,6 +668,7 @@
use the current Emacs frame\n\
-e, --eval Evaluate the FILE arguments as ELisp expressions\n\
-n, --no-wait Don't wait for the server to return\n\
+-q, --quiet Don't display messages on success\n\
-d DISPLAY, --display=DISPLAY\n\
Visit the file in the given display\n\
--parent-id=ID Open in parent window ID, via XEmbed\n"
@@ -986,7 +995,7 @@
if (! get_server_config (&server, auth_string))
return INVALID_SOCKET;
- if (server.sin_addr.s_addr != inet_addr ("127.0.0.1"))
+ if (server.sin_addr.s_addr != inet_addr ("127.0.0.1") && !quiet)
message (FALSE, "%s: connected to remote socket at %s\n",
progname, inet_ntoa (server.sin_addr));
@@ -1712,7 +1721,7 @@
send_to_emacs (emacs_socket, "\n");
/* Wait for an answer. */
- if (!eval && !tty && !nowait)
+ if (!eval && !tty && !nowait && !quiet)
{
printf ("Waiting for Emacs...");
needlf = 2;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r103486: Add --quiet option for emacsclient (bug#663) (tiny change),
Glenn Morris <=