From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jim Porter Newsgroups: gmane.emacs.bugs Subject: bug#59388: Open emacsclient file at last line Date: Sat, 19 Nov 2022 15:06:14 -0800 Message-ID: References: <835yfb7xo6.fsf@gnu.org> <518ded72c33c3608e35a@heytings.org> <83zgcm7rfg.fsf@gnu.org> <518ded72c37782cf8af5@heytings.org> <4dff4be5-8c53-8d8b-e912-1cf2bb3dff98@gmail.com> <83k03q7khf.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4434"; mail-complaints-to="usenet@ciao.gmane.io" Cc: gregory@heytings.org, xerusx@pm.me, 59388@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Nov 20 00:07:24 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1owWvk-0000vJ-0V for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 20 Nov 2022 00:07:24 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1owWvQ-0002qX-AX; Sat, 19 Nov 2022 18:07:04 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1owWvO-0002q5-9L for bug-gnu-emacs@gnu.org; Sat, 19 Nov 2022 18:07:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1owWvN-0005IL-WE for bug-gnu-emacs@gnu.org; Sat, 19 Nov 2022 18:07:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1owWvN-0005iE-Rg for bug-gnu-emacs@gnu.org; Sat, 19 Nov 2022 18:07:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Jim Porter Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 19 Nov 2022 23:07:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 59388 X-GNU-PR-Package: emacs Original-Received: via spool by 59388-submit@debbugs.gnu.org id=B59388.166889918621914 (code B ref 59388); Sat, 19 Nov 2022 23:07:01 +0000 Original-Received: (at 59388) by debbugs.gnu.org; 19 Nov 2022 23:06:26 +0000 Original-Received: from localhost ([127.0.0.1]:41635 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1owWun-0005hO-JS for submit@debbugs.gnu.org; Sat, 19 Nov 2022 18:06:25 -0500 Original-Received: from mail-pj1-f50.google.com ([209.85.216.50]:34767) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1owWuk-0005h9-9p for 59388@debbugs.gnu.org; Sat, 19 Nov 2022 18:06:24 -0500 Original-Received: by mail-pj1-f50.google.com with SMTP id w3-20020a17090a460300b00218524e8877so9436042pjg.1 for <59388@debbugs.gnu.org>; Sat, 19 Nov 2022 15:06:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id:from:to:cc :subject:date:message-id:reply-to; bh=HHSIlg/BuLhAoOKMryU9dMGs9KS/0oopvBWhUyuWvf8=; b=Ql2ZPjhtvnacFLSEoxLlYwiRT95VL4w3TWfRXgwuT42ZIZ4ZlTbpEEwU2zbGh2rNgl H5hdzvTceRVlzgey9eEVg+Y4Iq11tFoqZOt8nMYS4NYKGxoKiletLKUE0JFnZRmfwpWn PieueZVeT6QTxsVj4t7Cj7l/n1+H13M7LFZ6TgwOi9qdc6qRzSUKA2DFwyMPrYlInxeg fAAhb+/14wmqftTfywTSRgjd7z95uyECtXLoJLMTSMnYC9cZYa/lUBwnuEfVf+wOmT3g CUdlgToYfhuJC+gLfhlyYnIQidd+9RaGwxxj9IU0vvONEv92s/ucSRm01/M8rGDxvQW/ kq0w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=HHSIlg/BuLhAoOKMryU9dMGs9KS/0oopvBWhUyuWvf8=; b=ZhdIQF8WUySWk1tItNioxNP6dYmSjW252EhZ5LLkiqW0Awhn2lKO8vbH3v+HKGaUYM hKlqimSM7G2U7Yoaqh6VW5BWD7Y444JGIOjSDZ6tC3im03fJF4S/SI+zDQiPaVw3T4bS cpFknlH8XCxE512yqBApMccBSInONWPy1wc4tmRbh2tLBVdkND46MyHGTg4qQTGizCJd UgICw+aoYhcpl4mcvpuqPubC166T/srXSvNRTI500J6cBFJnEuCW/q8Hs9xdDwx3LETs xMPAR7aXcej4oWHkhN5QpKfWALvI6E1wF2KJlz0DdhZd9Ftxi3s3BAFVPusRQQCQA/3J M9DA== X-Gm-Message-State: ANoB5pmIVeBHKm0bf+wS0TyfblCXwdvTpV717dmT8LdRgSeIbB0Sf+EY jnBag3SrscDVdj++00g0zbk= X-Google-Smtp-Source: AA0mqf4D9MQhe9wA/TP+oZ0x5czBWSNKFwlNjTvdksGqPqvlUkwZo3Jv7sg5kd9zKglcyQ/fubBhOQ== X-Received: by 2002:a17:903:260d:b0:186:c56d:4950 with SMTP id jd13-20020a170903260d00b00186c56d4950mr5636550plb.69.1668899176243; Sat, 19 Nov 2022 15:06:16 -0800 (PST) Original-Received: from [192.168.1.2] (cpe-76-168-148-233.socal.res.rr.com. [76.168.148.233]) by smtp.googlemail.com with ESMTPSA id y3-20020aa793c3000000b0056d7cc80ea4sm5618890pff.110.2022.11.19.15.06.14 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 19 Nov 2022 15:06:15 -0800 (PST) Content-Language: en-US In-Reply-To: <83k03q7khf.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:248380 Archived-At: On 11/19/2022 12:33 PM, Eli Zaretskii wrote: >> Date: Sat, 19 Nov 2022 12:08:06 -0800 >> Cc: xerusx@pm.me, 59388@debbugs.gnu.org >> From: Jim Porter >> >> 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.