GNU bug report logs -
#59388
Open emacsclient file at last line
Previous Next
Full log
Message #44 received at 59388 <at> debbugs.gnu.org (full text, mbox):
On 11/19/2022 12:33 PM, Eli Zaretskii wrote:
>> Date: Sat, 19 Nov 2022 12:08:06 -0800
>> Cc: xerusx <at> pm.me, 59388 <at> debbugs.gnu.org
>> From: Jim Porter <jporterbugs <at> gmail.com>
>>
>> 1. Why does --eval do that? You can mix filenames and --eval with the
>> regular emacs program:
>>
>> emacs -Q foo.txt --eval '(message "hi")'
>>
>> Why doesn't emacsclient work similarly? (On the other hand, changing
>> this might break compatibility, so we should be careful here.)
>
> I don't think we can change the semantics of --eval.
Yeah, probably not. I'm not sure how important fixing this inconsistency
is, but if we *were* to fix it, I think the least-disruptive would be to
add a new option like "emacsclient --eval-one" that behaves like "emacs
--eval" and add an obsoletion warning to "emacsclient --eval". Then,
after a few versions, make "emacsclient --eval" work like "emacsclient
--eval-one".
This might be more effort than it's worth though...
> Maybe we don't need to go as far as that discussion led us? Just adding a
> switch --funcall, to mimic what Emacs has, could be enough? Then we'd be
> able to say
>
> emacsclient -f eob FILE
>
> (assuming we also add a function 'eob' to Emacs).
With the caveat that -f is already used for --server-file, I think this
would be fine. --funcall is a lot simpler to implement than --apply, at
least from emacsclient.
This bug report was last modified 2 years and 204 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.