Closed jvdydev closed 8 months ago
Not a bad idea. The difficulty I can see would be all the extra files Emacs creates in those folders. Essentially, .../examples/elpaca-el
becomes user-emacs-directory
so the elpaca
folder will be created there at a minimum. These are untracked files in the crafted-emacs
repository. Not a big deal unless someone runs the appropriate git commands to add and then attempt to push those changes. I might prefer having a nifty elisp
file that would basically create a temporary "try it" directory at some place of the user's choosing, copies the early-init.el
and init.el
to those locations and (maybe) starts an instance of Emacs with that configuration for them to use.
I see your point, we could use a simple examples/<example>/.gitignore
like:
*
!.gitignore
!init.el
!early-init.el
Although I guess an ELisp script would work too, something like:
emacs --script crafted-emacs-try-example -- elpaca ~/test/trying-out-elpaca
emacs --init-directory ~/test/trying-out-elpaca
This would also allow users for tinkering with the example without tracking those changes in the crafted-emacs
git
I like the idea and the solution with the gitignore file. Seems to fit the bill...
I wonder if it would be nice to allow loading the examples using e.g.
emacs --init-directory
(for Emacs 29). This way, users could try out different example configurations without much hassle.Would also allow to change some examples to no longer require to use the
custom-modules
mechanism. The layout would look something like:Just a thought, open for discussion.