diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2022-10-28 23:22:22 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2022-10-29 21:53:13 -0700 |
commit | b4adeea21740d94cab6e0061aabf22c4ee151618 (patch) | |
tree | 3a0ada4bc465744ce517639b36adfc1d9b4a3d5b /.emacs.d | |
parent | d654248610f165b4fc5f8aaa88ceb142b371b016 (diff) | |
download | dotfiles-b4adeea21740d94cab6e0061aabf22c4ee151618.tar.gz |
replace emacs.git workstation integration commit
Also attempt to improve readability & commenting in wrapper script.
Archival copy of the workstation integration commit we're replacing:
Date: Sat, 25 Dec 2021 18:05:21 -0700
Subject: Workstation integration of personal development builds branch
---
admin/flagfile.melete | 0
lib-src/emacsclient.c | 7 +++++--
lisp/emacs-lisp/package.el | 1 +
lisp/startup.el | 7 ++++++-
4 files changed, 12 insertions(+), 3 deletions(-)
create mode 100644 admin/flagfile.melete
diff --git a/admin/flagfile.melete b/admin/flagfile.melete
new file mode 100644
index 00000000000..e69de29bb2d
diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c
index 425db8cface..62d71559d3c 100644
--- a/lib-src/emacsclient.c
+++ b/lib-src/emacsclient.c
@@ -1794,7 +1794,10 @@ start_daemon_and_retry_set_socket (void)
}
else
{
- char emacs[] = "emacs";
+ const char *devel_build_rel = "/src/emacs/src/emacs";
+ char *emacs = xmalloc (strlen (egetenv ("HOME"))
+ + strlen (devel_build_rel) + 1);
+ strcpy ( stpcpy (emacs, egetenv ("HOME")), devel_build_rel);
char daemon_option[] = "--daemon";
char *d_argv[3];
d_argv[0] = emacs;
@@ -1811,7 +1814,7 @@ start_daemon_and_retry_set_socket (void)
d_argv[1] = daemon_arg;
}
# endif
- execvp ("emacs", d_argv);
+ execvp (emacs, d_argv);
message (true, "%s: error starting emacs daemon\n", progname);
exit (EXIT_FAILURE);
}
diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el
index d619142d64c..d464e120193 100644
--- a/lisp/emacs-lisp/package.el
+++ b/lisp/emacs-lisp/package.el
@@ -312,6 +312,7 @@ package-directory-list
(and (stringp f)
(equal (file-name-nondirectory f) "site-lisp")
(push (expand-file-name "elpa" f) result)))
+ (push "/usr/share/emacs-snapshot/site-lisp/elpa" result)
(nreverse result))
"List of additional directories containing Emacs Lisp packages.
Each directory name should be absolute.
diff --git a/lisp/startup.el b/lisp/startup.el
index 725984b815b..e10d854c368 100644
--- a/lisp/startup.el
+++ b/lisp/startup.el
@@ -1452,7 +1452,12 @@ command-line
;; be loaded from site-run-file and wants to test if -q was given
;; should check init-file-user instead, since that is already set.
;; See cus-edit.el for an example.
- (if site-run-file
+ (when site-run-file
+ (let ((file "/etc/emacs/site-start.d/00debian.el"))
+ ;; When the Emacs build invokes Emacs, such as in the
+ ;; Makefile rule for ${unidir}/emoji-labels.el, 00debian.el
+ ;; might not exist. Should be fine to just skip the load.
+ (when (file-readable-p file) (load file)))
;; Sites should not disable the startup screen.
;; Only individuals should disable the startup screen.
(let ((inhibit-startup-screen inhibit-startup-screen))
Diffstat (limited to '.emacs.d')
-rw-r--r-- | .emacs.d/early-init.el | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/.emacs.d/early-init.el b/.emacs.d/early-init.el index c3d67b50..23f3c6a2 100644 --- a/.emacs.d/early-init.el +++ b/.emacs.d/early-init.el @@ -5,6 +5,20 @@ ;; Released under the terms of the GNU GPL as published by the FSF; either ;; version 3, or (at your option) any later version. +(when (file-in-directory-p invocation-directory (expand-file-name "~/")) + ;; Make packages compiled against my emacs-snapshot Debian packages + ;; available to in-tree builds too. (Used to do this by patching the code + ;; computing the default value of `package-directory-list' in those builds.) + (when (file-directory-p "/usr/share/emacs-snapshot/site-lisp/elpa") + (add-to-list 'package-directory-list + "/usr/share/emacs-snapshot/site-lisp/elpa" t)) + + ;; Run Debian's site-start library site-run-file for in-tree builds too. + ;; (Used to do this by patching `command-line' in those builds.) + (when (file-readable-p "/etc/emacs/site-start.d/00debian.el") + (load "/etc/emacs/site-start.d/00debian.el"))) + + ;;; Per docstring for `after-make-frame-functions', these additions to that ;;; list of functions are made in this file in order that they can affect the ;;; initial frame. |