jkitchin / scimax

An emacs starterkit for scientists and engineers
Other
1.03k stars 123 forks source link

Recommended way to use the new early-init.el with scimax #459

Closed JSpenced closed 1 year ago

JSpenced commented 2 years ago

I want to add the following to my emacs config to eliminate the borders (used to use a patch for this prior to emacs 29, but this is the recommended way going forward): (add-to-list 'default-frame-alist '(undecorated . t))

It needs to be added to the early-init.el but we start with -q -l scimax/init.el, so wondering the recommended way to do this or if you have used an early-init.el beofre?

JSpenced commented 2 years ago

FYI, I am doing this with this command to start nohup emacs -q -l ${HOME}/Programs/scimax/early-init.el </dev/null >/dev/null 2>&1 & and it works fine:

;;; early-init.el --- Where early initialization files can be loaded before the gui
;;

(add-to-list 'default-frame-alist '(undecorated . t))

(load "~/Programs/scimax/init.el")

I will probably add some other UI elements to default-frame-alist that I don't load because apparently makes startup a bit faster. I wanted your rec if there was a better way to do this first though.

jkitchin commented 2 years ago

you can try putting that into a user/preload.el file. That is one of the first things to be loaded (https://github.com/jkitchin/scimax/blob/master/init.el#L34). scimax doesn't have an early-init file other than that one.

Or, create your early-init.el file, and at the end, load the scimax/init.el file, and start scimax with emacs -q -l early-init.el.