]> git.earman.xyz Git - emacsinit.git/commitdiff
Match LarsTvei's Meta-config
authorrearman <rearman@r717.net>
Wed, 15 Mar 2023 16:11:06 +0000 (12:11 -0400)
committerrearman <rearman@r717.net>
Wed, 15 Mar 2023 16:11:06 +0000 (12:11 -0400)
init.el
init.org

diff --git a/init.el b/init.el
index 0ad76919bd10b1df13d4e9d0a2c38ccf55dbf9d7..0321d276426d5c52f32c75373439979e3a47cb41 100644 (file)
--- a/init.el
+++ b/init.el
@@ -1,7 +1,10 @@
+;;; This file replaces itself with the real config at first run
 ;; We Can't tangle without org!
 (require 'org)
-;; Create the real config...
-(org-babel-tangle (concat user-emacs-directory "init.org"))
+;; Open the config...
+(find-file (concat user-emacs-directory "init.el"))
+;; Tangle it...
+(org-babel-tangle)
 ;; Load it...
 (load-file (concat user-emacs-directory "init.el"))
 ;; And compile it
index ce1ae19ac2cd43664f0958dc0fe876682b9534d1..ed34b2b475f7c0d95736fc065df46a2e8d04d54f 100644 (file)
--- a/init.org
+++ b/init.org
@@ -18,14 +18,17 @@ I have taken this mostly whole-hog from [[https://github.com/larstvei/dot-emacs]
 
 This is the repo's =init.el= file, which bootstraps the real =init.el=.
 #+BEGIN_SRC emacs-lisp :tangle no
+;;; This file replaces itself with the real config at first run
 ;; We Can't tangle without org!
 (require 'org)
-;; Create the real config...
-(org-babel-tangle (concat user-emacs-directory "init.org"))
+;; Open the config...
+(find-file (concat user-emacs-directory "init.el"))
+;; Tangle it...
+(org-babel-tangle)
 ;; Load it...
 (load-file (concat user-emacs-directory "init.el"))
 ;; And compile it
-(byte-compile (concat user-emacs-directory "init.el"))
+(byte-compile-file (concat user-emacs-directory "init.el"))
 #+END_SRC
 
 There is no reason to track the =init.el= that is generated.  Run the following command to make git ignore the generated file, but keep the dummy init.