emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How does Emacs load a non-existent .el file?


From: Konstantin Kharlamov
Subject: Re: How does Emacs load a non-existent .el file?
Date: Fri, 01 Mar 2024 17:15:21 +0300
User-agent: Evolution 3.50.4

On Fri, 2024-03-01 at 15:45 +0200, Eli Zaretskii wrote:
> > From: Konstantin Kharlamov <Hi-Angel@yandex.ru>
> > Cc: emacs-devel@gnu.org
> > Date: Fri, 01 Mar 2024 16:30:07 +0300
> > 
> > > Yes: startup.el is preloaded, see lisp/loadup.el.  So if you
> > > change
> > > it, you need to rebuild Emacs to let the changes have their
> > > effect at
> > > startup.  You can also load startup.el manually into a running
> > > session, and then invoke functions you've changed, but that will
> > > only
> > > be useful if what you are changing is not some special behavior
> > > that
> > > happens only at startup.
> > 
> > Okay, I see, so the `startup.el` is a dummy file that's not being
> > read.
> 
> It isn't a "dummy file".  It is not being read in your scenario, but
> that's not all there is to it.
> 
> > I wonder if it's too hard to add to `*Help*` buffer mention that
> > certain functions are not being read from the file where the buffer
> > claims that they reside.
> 
> That claim is correct, so why change it?

What claim? I'm pointing out the lack of information in *Help* buffer
that certain functions are not read from the location where *Help*
claims them to be. That confuses, so I'm just wondering if it's too
hard to modify help function to add a note about such functions (ofc if
this information is globally available, which Idk if it is)

> > > There are a few answers there that solve the problem, so I'm not
> > > sure
> > > what else are you trying to do, and why.
> > 
> > I see only one answer that is more or less convenient, which is
> > `emacs
> > --insert <(echo 123)`.
> 
> No, there's also an answer using --script, for example.

This answer is part of those "rest of them" that I mentioned that
require writing a script 😊

> > I agree with the opinion of one of the commenters here: this is
> > absolutely basic feature that most editors have. Not having it in
> > Emacs
> > is very strange.
> 
> I actually find it strange that someone wants it.  The need was never
> explained.  The fact that we don't have it speaks volumes about the
> need (or lack thereof).

That's not how it works. Emacs is not an ordinary project (90% of open
source projects do not require signing docs with FSF and using a mail-
managed bugtracker for patches), so I'm sure many potential
contributors are getting lost on that part.

Another point: I use reading from stdin from time to time, mostly at
work, but I always used `vim -` for that purpose because with the
amount of plugins I have Emacs startup is not instant. It's only now
that I migrate to using `emacsclient` for quick edits from terminal I
found out that Emacs was never able to read from stdin. And I am an
Emacs contributor. So there you have it: a contributor who uses
"reading from stdin" but who did not even know Emacs can't do that.

Instead what matters is the amount of views and upvotes on the linked
Emacs question: 16k. As someone who often gets stackexchange sites in
search-engine results while figuring out how to do something in Emacs,
I can assure you that 16k views and 47 upvotes on an Emacs-related
question makes it one of the top ones.

> Of course, if this is your itch, feel free to scratch it, regardless.
> Don't mind me.

Thank you 😊 I'll look into that, but won't promise. I don't know yet
what needs to be done (btw, in case anybody knows, pointers are
appreciated), but if it's not too hard I might try adding that.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]