[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 75b8492: Rename '--new-daemon' to 'fg-daemon' and '
From: |
Noam Postavsky |
Subject: |
[Emacs-diffs] master 75b8492: Rename '--new-daemon' to 'fg-daemon' and '--old-daemon' to '--bg-daemon' |
Date: |
Mon, 29 May 2017 22:23:13 -0400 (EDT) |
branch: master
commit 75b849294656fd92e77a2a6281ff4dceaaa38475
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>
Rename '--new-daemon' to 'fg-daemon' and '--old-daemon' to '--bg-daemon'
* doc/emacs/cmdargs.texi (Initial Options):
* doc/lispref/os.texi (Startup Summary):
* etc/NEWS:
* etc/emacs.service:
* src/emacs.c (main):
* src/lisp.h: Rename '--new-daemon' to 'fg-daemon' and '--old-daemon' to
'--bg-daemon'.
---
doc/emacs/cmdargs.texi | 8 ++++----
doc/lispref/os.texi | 6 +++---
etc/NEWS | 5 +++--
etc/emacs.service | 2 +-
src/emacs.c | 18 +++++++++---------
src/lisp.h | 2 +-
6 files changed, 21 insertions(+), 20 deletions(-)
diff --git a/doc/emacs/cmdargs.texi b/doc/emacs/cmdargs.texi
index 6f76ef3..0b1a400 100644
--- a/doc/emacs/cmdargs.texi
+++ b/doc/emacs/cmdargs.texi
@@ -336,16 +336,16 @@ setting @code{inhibit-x-resources} to @code{t}
(@pxref{Resources}).
@opindex -daemon
@itemx address@hidden
@opindex --daemon
address@hidden address@hidden
address@hidden address@hidden
address@hidden address@hidden
address@hidden address@hidden
Start Emacs as a daemon---after Emacs starts up, it starts the Emacs
server without opening any frames.
(Optionally, you can specify an explicit @var{name} for the server.)
You can then use the @command{emacsclient} command to connect to Emacs
for editing. @xref{Emacs Server}, for information about using Emacs
-as a daemon. An ``old-style'' daemon disconnects from the terminal
+as a daemon. A ``background'' daemon disconnects from the terminal
and runs in the background (@samp{--daemon} is an alias for
address@hidden).
address@hidden).
@item --no-desktop
@opindex --no-desktop
diff --git a/doc/lispref/os.texi b/doc/lispref/os.texi
index 438f48c..e6ec60f 100644
--- a/doc/lispref/os.texi
+++ b/doc/lispref/os.texi
@@ -337,10 +337,10 @@ Do not display a splash screen.
Run without an interactive terminal. @xref{Batch Mode}.
@item --daemon
address@hidden --old-daemon
address@hidden --new-daemon
address@hidden --bg-daemon
address@hidden --fg-daemon
Do not initialize any display; just start a server.
-(An ``old-style'' daemon automatically runs in the background.)
+(A ``background'' daemon automatically runs in the background.)
@item --no-init-file
@itemx -q
diff --git a/etc/NEWS b/etc/NEWS
index 60066b7..14cada4 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -78,10 +78,11 @@ affected by this, as SGI stopped supporting IRIX in
December 2013.
* Startup Changes in Emacs 26.1
-** New option '--new-daemon'. This is the same as '--daemon', except
++++
+** New option '--fg-daemon'. This is the same as '--daemon', except
it runs in the foreground and does not fork. This is intended for
modern init systems such as systemd, which manage many of the traditional
-aspects of daemon behavior themselves. '--old-daemon' is now an alias
+aspects of daemon behavior themselves. '--bg-daemon' is now an alias
for '--daemon'.
+++
diff --git a/etc/emacs.service b/etc/emacs.service
index d9f7fc5..b29177b 100644
--- a/etc/emacs.service
+++ b/etc/emacs.service
@@ -8,7 +8,7 @@ Documentation=info:emacs man:emacs(1)
https://gnu.org/software/emacs/
[Service]
Type=simple
-ExecStart=emacs --new-daemon
+ExecStart=emacs --fg-daemon
ExecStop=emacsclient --eval "(kill-emacs)"
Environment=SSH_AUTH_SOCK=%t/keyring/ssh
Restart=on-failure
diff --git a/src/emacs.c b/src/emacs.c
index 4477f5b..6ed16e8 100644
--- a/src/emacs.c
+++ b/src/emacs.c
@@ -219,8 +219,8 @@ Initialization options:\n\
"\
--batch do not do interactive display; implies -q\n\
--chdir DIR change to directory DIR\n\
---daemon, --old-daemon[=NAME] start a (named) server in the background\n\
---new-daemon[=NAME] start a (named) server in the foreground\n\
+--daemon, --bg-daemon[=NAME] start a (named) server in the background\n\
+--fg-daemon[=NAME] start a (named) server in the foreground\n\
--debug-init enable Emacs Lisp debugger for init file\n\
--display, -d DISPLAY use X server DISPLAY\n\
",
@@ -991,15 +991,15 @@ main (int argc, char **argv)
int sockfd = -1;
- if (argmatch (argv, argc, "-new-daemon", "--new-daemon", 10, NULL,
&skip_args)
- || argmatch (argv, argc, "-new-daemon", "--new-daemon", 10, &dname_arg,
&skip_args))
+ if (argmatch (argv, argc, "-fg-daemon", "--fg-daemon", 10, NULL, &skip_args)
+ || argmatch (argv, argc, "-fg-daemon", "--fg-daemon", 10, &dname_arg,
&skip_args))
{
daemon_type = 1; /* foreground */
}
else if (argmatch (argv, argc, "-daemon", "--daemon", 5, NULL, &skip_args)
|| argmatch (argv, argc, "-daemon", "--daemon", 5, &dname_arg,
&skip_args)
- || argmatch (argv, argc, "-old-daemon", "--old-daemon", 10, NULL,
&skip_args)
- || argmatch (argv, argc, "-old-daemon", "--old-daemon", 10, &dname_arg,
&skip_args))
+ || argmatch (argv, argc, "-bg-daemon", "--bg-daemon", 10, NULL,
&skip_args)
+ || argmatch (argv, argc, "-bg-daemon", "--bg-daemon", 10, &dname_arg,
&skip_args))
{
daemon_type = 2; /* background */
}
@@ -1114,7 +1114,7 @@ Using an Emacs configured with --with-x-toolkit=lucid
does not have this problem
char fdStr[80];
int fdStrlen =
snprintf (fdStr, sizeof fdStr,
- "--old-daemon=\n%d,%d\n%s", daemon_pipe[0],
+ "--bg-daemon=\n%d,%d\n%s", daemon_pipe[0],
daemon_pipe[1], dname_arg ? dname_arg : "");
if (! (0 <= fdStrlen && fdStrlen < sizeof fdStr))
@@ -1711,8 +1711,8 @@ static const struct standard_args standard_args[] =
{ "-batch", "--batch", 100, 0 },
{ "-script", "--script", 100, 1 },
{ "-daemon", "--daemon", 99, 0 },
- { "-old-daemon", "--old-daemon", 99, 0 },
- { "-new-daemon", "--new-daemon", 99, 0 },
+ { "-bg-daemon", "--bg-daemon", 99, 0 },
+ { "-fg-daemon", "--fg-daemon", 99, 0 },
{ "-help", "--help", 90, 0 },
{ "-nl", "--no-loadup", 70, 0 },
{ "-nsl", "--no-site-lisp", 65, 0 },
diff --git a/src/lisp.h b/src/lisp.h
index 7290386..7b8f1e7 100644
--- a/src/lisp.h
+++ b/src/lisp.h
@@ -4167,7 +4167,7 @@ extern bool no_site_lisp;
extern bool build_details;
#ifndef WINDOWSNT
-/* 0 not a daemon, 1 new-style (foreground), 2 old-style (background). */
+/* 0 not a daemon, 1 foreground daemon, 2 background daemon. */
extern int daemon_type;
#define IS_DAEMON (daemon_type != 0)
#define DAEMON_RUNNING (daemon_type >= 0)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master 75b8492: Rename '--new-daemon' to 'fg-daemon' and '--old-daemon' to '--bg-daemon',
Noam Postavsky <=