From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 9641 invoked from network); 18 Dec 2023 19:37:35 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 18 Dec 2023 19:37:35 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1702928255; b=NbmZL8TxK07A/A/AnPPRIjk5jnauTZ75i6Lt8MWuy15vX+4CAQlq9QpNBevqiI6zYaElJfKUi/ 7QwGt2ZHdj2hiD7w1MNJLlqmyOVgJ252EI5V4mGfP2mk5jWLWEgRqAGekKuMo+7TGNgbbM9rtg Wv5jGDALtkbrpqWguM0oYxOopkmoTf9dylVIJ44GaNVJJPx8CKuMEHxdYw76HEU8P/kqpQ3gLO NJ8ChrakZlntw+fht+gL7FQHM/p4NzXPV7g9GgJqH8GmY9aNKHKs/hRR+Og4jz9GaoSXPZxvE2 Pa+90gOYAkOfIqBuPZsxLcQ60AfCukz2ljNwI4zuJDGMzw==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (joooj.vinc17.net) smtp.remote-ip=155.133.131.76; dmarc=none header.from=vinc17.net; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1702928255; bh=6YFun235lgY1N8wkGgFSAKUcYEa+p+306vSy+OLBblE=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:In-Reply-To:Content-Transfer-Encoding:Content-Type: MIME-Version:References:Message-ID:Subject:To:From:Date:DKIM-Signature; b=JLVxpOCYBwb9/KRJR+ljGs96uryeTxGrQBrlyyflEVINVfw6JKyEwunGdUBROQauKTUDyWf4v+ qPwJh+Mw5aSOnphsEK10Op2ZlC0OBqA/Ky6KK4f4eXwYft9xWqtTSMSncOnce2z4q/8DrQUF6t LQMi9OJiALwClIs1DfiUK77+R7oAQWJ3E51tKbZW1U++AGjFV92b0lcs8lHkEXXNOKXMyELt23 uA7OaRfAdnvodbiAzeo1Gwb5GuG9q7hXT9Diu4YkYG+PyCC+A3ylKQoUKtqdbvachCotjh+bgz pcuM98yA0s7XmExb1JDILsh448Pb+dtB8PLKIyMZ5vjBPw==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:In-Reply-To:Content-Transfer-Encoding :Content-Type:MIME-Version:References:Message-ID:Subject:To:From:Date: Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=ckEslUjClncG0ySlEPsUdyImzEpLI91U3ISS4ZHqeUI=; b=mdzN4EIV38/5LjDNtwNoGNBVU3 2WcTrATLydlD0ceJo1s5ztfT2EoLoiXTmyln0/ksuSsNWAvmsgyqUQZPpkZqi4SEz5k03hHTYHNAw CwljndQqc3dtX0pqFd3WymLIat3/aR5I2yNg45lLuLDP6iv/701WdeBZ/GWXIIxHTvDc2dbnVh6y5 x1dAxDgWqRh7o9LHx2s3XmEkMAUH64TeejdfcMZBOJEbhW/CFTwDZ+nHJWP9FuML+MnWH4Iv8ktgJ DEYnBWFygPIMa2oMefUC2jrEh364tlyXwYymtPxfiA4+w4U6odqPI7PRZ8I3VJUGplcVG1Z1cpuWQ S69ly/dA==; Received: by zero.zsh.org with local id 1rErbB-0008TZ-Hu; Sun, 17 Dec 2023 13:54:29 +0000 Authentication-Results: zsh.org; iprev=pass (joooj.vinc17.net) smtp.remote-ip=155.133.131.76; dmarc=none header.from=vinc17.net; arc=none Received: from joooj.vinc17.net ([155.133.131.76]:56452) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1rEraq-0008By-SN; Sun, 17 Dec 2023 13:54:10 +0000 Received: from smtp-zira.vinc17.net (2a02-8428-1b1d-4d01-9274-9d43-0c1c-f0d1.rev.sfr.net [IPv6:2a02:8428:1b1d:4d01:9274:9d43:c1c:f0d1]) by joooj.vinc17.net (Postfix) with ESMTPSA id 22918669; Sun, 17 Dec 2023 14:54:08 +0100 (CET) Received: by zira.vinc17.org (Postfix, from userid 1000) id E13B92800199; Sun, 17 Dec 2023 14:54:07 +0100 (CET) Date: Sun, 17 Dec 2023 14:54:07 +0100 From: Vincent Lefevre To: zsh-workers@zsh.org Subject: Re: [BUG] With CORRECT_ALL, an interrupted correct puts a truncated entry in history Message-ID: <20231217135407.GA3237@zira.vinc17.org> Mail-Followup-To: zsh-workers@zsh.org References: <20231205021217.GA357346@zira.vinc17.org> <20231205125732.GA1126552@cventin.lip.ens-lyon.fr> <20231206150333.GA385094@zira.vinc17.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Mailer-Info: https://www.vinc17.net/mutt/ User-Agent: Mutt/2.2.12+67 (757ca3b3) vl-149028 (2023-09-09) X-Seq: 52416 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: , List-Subscribe: , List-Unsubscribe: , List-Post: List-Owner: List-Archive: On 2023-12-09 13:44:42 -0800, Bart Schaefer wrote: > On Wed, Dec 6, 2023 at 7:03 AM Vincent Lefevre wrote: > > > > On 2023-12-05 13:22:07 -0800, Bart Schaefer wrote: > > > On Tue, Dec 5, 2023 at 4:57 AM Vincent Lefevre wrote: > > > > > > > > I thought that this would have been put in a temporary buffer, > > > > until the (possibly corrected) command is validated. > > > > > > I'm not sure what you think "validated" means here. > > > > Once the user has no longer any way to discard the command line, > > which will then be really run. > > Ah. It's in the buffer managed in ZLE as $BUFFER, but corrections > apply left to right as that buffer is converted into a parse tree, > they don't alter the buffer itself. But if one does a first correction, for the second proposed correction, one types 'e' to edit, one gets the buffer with the first correction applied. > > Or just use 'e', then immediately put the command in the history > > without running it. Is there a zle widget for that? I would find > > this useful even when there are no spelling corrections. > > That would be push-input, which is not bound to anything by default, > but could probably be bound to ESC (shift)Q without disrupting use of > push-line on ESC q. > > Correction is not itself a ZLE action -- it happens after ZLE has > returned control to the parser, and works even if ZLE is disabled. So > there's no widget to fiddle with it. But what matters to that after 'e', one is in ZLE. -- Vincent Lefèvre - Web: 100% accessible validated (X)HTML - Blog: Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)