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,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 10392 invoked from network); 28 Feb 2021 13:26:27 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 28 Feb 2021 13:26:27 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1614518787; b=kllg+qvSR2dQUbpryOpZrk5JNAlWMEJ8URvmVrGgNJpNgTYyDS6OpqAUwz/mAzb9m7AXMH8JSr 9E8RN//93nOByN+ucwz+NEvCyaG08cALB+SRfkJl+M3gX3Fvwc3/l0kaD8fsIhvu9pjQLH4x6v KRwMVPOlfjzUFGbvdHDLac4Ok5B42Lh1h38YzEXQ5CaQWStFrLPTc0O3nk6ts7qQtxaQAq2si/ yNy0PiEdNZ9NdX+SNy1TBxLInW4HHCw8/ANhdAB0qzax1X24FFabWKHnPfjn5YA7QF1r80jtcC VqmNoP5HQON+1IIZDuVIfySltuHvzQz8NicYx4be7JbaZw==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (hekla.abc.se) smtp.remote-ip=158.174.61.227; dmarc=none header.from=abc.se; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1614518787; bh=95ig5321997aodLnjVjyRmtOz0GYiYyfJp+eoHFzMXw=; 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:Cc:To:From:Date:DKIM-Signature; b=XB2D5NyqS68+9d9LGMsxrzx1spgsPVvY6bNCgmVhAldT54B2YdnFiceQxM1QbqvrFpdW6E6GYf Jpgo7r4+LWTeubBOuP7cT1mkB4ObvJno4oG/U9l3S/OErF1212AGHNBjbjUR+WQAUSTtnog5uh vpSAWixbwDmBQ4gecT8DE7wcU5PkRNyO1B5t3cfvy2HaBrZMlu1J0OfQLMtLBLB53nZdbU4gko BIV3FZakyTANtzZ3DTtsJFSZ67dAMQv2eDE3RiF3ke9jrqM0vEeSdge5ZCIW/cqRf3uq/wbRyq /kV73uPAfIbLshMadLDrppR9ybeokop29Uknw0bpph5k1Q==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; 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:Cc:To:From:Date: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID; bh=LhbSV9cFY1EJYFGpz7/DqKn9oYwNb4Xlq41bRyaGfl0=; b=PmBTbVtvvT8i5Ge5NNTddKkEfB CSDIxeM1i8kbLRWbeVhdrC6/c/UrriFjlOuXIY39gsip/uhvnk2CFF+FjQQfXLCaQW+hthCPd7WG0 0PZHHvLbEpm63GyaI6Tw8hJ3zd20besDZ9Rqg7IcXKs1nhgJAR7oQk5pK2506irNVxKRllC7kB4Mc M2Gz7mRgHvYt/BkzObUwgiJMzlPlk7k5jVUNRi/vKiwrOEhto1evWqo6MexZCoaudm7s/OCDWrW1S dr6dI7TJ8vn+yN92GFbIuNKsdwqnZ6GGiIUIta2+XorACy1q3FSYI6L/8WcWpsObFh0Hcl//zPany 0KAAcvtg==; Received: from authenticated user by zero.zsh.org with local id 1lGM5V-000BLI-7c; Sun, 28 Feb 2021 13:26:21 +0000 Authentication-Results: zsh.org; iprev=pass (hekla.abc.se) smtp.remote-ip=158.174.61.227; dmarc=none header.from=abc.se; arc=none Received: from hekla.abc.se ([158.174.61.227]:18273) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_256_GCM_SHA384:256) id 1lGM50-000Axd-Pa; Sun, 28 Feb 2021 13:25:51 +0000 Received: from eeyore.prefix.duckdns.org (83-233-145-220.cust.bredband2.com [83.233.145.220]) by hekla.abc.se (OpenSMTPD) with ESMTPSA id 6c01527c (TLSv1.3:AEAD-AES256-GCM-SHA384:256:NO); Sun, 28 Feb 2021 14:25:46 +0100 (CET) Received: from box.prefix.duckdns.org (box.prefix.duckdns.org [192.168.1.50]) by eeyore.prefix.duckdns.org (OpenSMTPD) with ESMTP id ee6587db; Sun, 28 Feb 2021 14:25:45 +0100 (CET) Received: from localhost (box.prefix.duckdns.org [local]) by box.prefix.duckdns.org (OpenSMTPD) with ESMTPA id 1c98bbd7; Sun, 28 Feb 2021 14:25:45 +0100 (CET) Date: Sun, 28 Feb 2021 14:25:45 +0100 From: Andreas Kusalananda =?utf-8?B?S8OkaMOkcmk=?= To: Peter Stephenson Cc: zsh-users@zsh.org Subject: Re: Repeating last command from *local* history Message-ID: <20210228132545.GA76759@box.prefix.duckdns.org> Mail-Followup-To: Peter Stephenson , zsh-users@zsh.org References: <20210211163728.GA8608@box.prefix.duckdns.org> <27299937c9c060b1a8ed1acbce6cda5c72d63a64.camel@ntlworld.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <27299937c9c060b1a8ed1acbce6cda5c72d63a64.camel@ntlworld.com> X-Seq: 26558 Archived-At: X-Loop: zsh-users@zsh.org Errors-To: zsh-users-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-users-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: Archived-At: On Thu, Feb 11, 2021 at 08:47:46PM +0000, Peter Stephenson wrote: > On Thu, 2021-02-11 at 17:37 +0100, Andreas Kusalananda Kähäri wrote: > > I'm using zsh 5.8 on OpenBSD 6.8, and I set the SHARE_HISTORY and > > EXTENDED_HISTORY shell options. > > > > I would like to repeat the last command from the command line history > > of the current shell session, without accidentally executing a recent > > command from some other shell session that I'm using in another > > terminal. > > > > Using "r -L" works, but only if the most recent command in the shared > > history is a command from the current shell session. If it isn't, the > > shell responds with "fc: no matching events found". > > > > This *feels* like a bug. > > Yes, it's a typical "computer says no" bug. > > I thin this one's easy, although it's possible there are more implications > here than I'm picking up... > > pws > The patch seems to have made it into the zsh Git repository. I've re-built the shell from there and "r -L" now seems to work the way I was initially expecting it to work. Thanks for this! Regards, -- Andreas (Kusalananda) Kähäri SciLifeLab, NBIS, ICM Uppsala University, Sweden .