From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20290 invoked by alias); 16 Dec 2014 03:58:14 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 19549 Received: (qmail 21978 invoked from network); 16 Dec 2014 03:58:09 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HTML_MESSAGE,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=aw04P8tOahSizf1atVNHhkjutks5YXRmwbyphgb40OY=; b=orE4AjpMsQ1qlggVWHhZu2ouBDGta/Fw708vNRWbMGlsJwfCoYm0nBJ6kZ7tqjAaxX W9+Za+xrPY4dWszb6ZYTl9pdUBOyKLpTnAGp5n6Oy6g4hPEB99Js+gFGXu2wVSv/CKKD /Ia3IfGRojuuDb5muVUHR/W3DgcpFzVWVlzLrdBh9sxTTG9Uvdji+MNpyXWvPRqc6/cY af4SzH2WdsGU+y4xnUzdIX3BOY2s3S7QpHTE7ZqZHmJaCGd/QIuyEzMkRT4IdkPDz+tt xl0nX1clIbGco2z1sYhg4Wb6w+dBjz9ECGC3mqJJT4BhpiQGXWZsXRYIJdokXNuq/VVE zQHw== MIME-Version: 1.0 X-Received: by 10.194.188.39 with SMTP id fx7mr55630246wjc.113.1418702285122; Mon, 15 Dec 2014 19:58:05 -0800 (PST) Sender: rocky.bernstein@gmail.com In-Reply-To: References: <141214185332.ZM24112@torch.brasslantern.com> <141215003717.ZM24212@torch.brasslantern.com> <141215081440.ZM25053@torch.brasslantern.com> Date: Mon, 15 Dec 2014 22:58:05 -0500 X-Google-Sender-Auth: ZnerNL_YwE8RFPdcyXB5COh8FIU Message-ID: Subject: Re: An example of writing a custom history file? From: Rocky Bernstein To: Mikael Magnusson Cc: Bart Schaefer , Zsh Users Content-Type: multipart/alternative; boundary=047d7bb04002bf333b050a4d5d63 --047d7bb04002bf333b050a4d5d63 Content-Type: text/plain; charset=UTF-8 On Mon, Dec 15, 2014 at 1:22 PM, Mikael Magnusson wrote: > On Mon, Dec 15, 2014 at 6:05 PM, Rocky Bernstein > wrote: > > Making the change suggested, adding 1000 doesn't change the behavior - no > > file is written. Again, here is the entire 12-line program: > > Please don't top post. > > I was able to get your example to work as-is by adding -i to the > hashbang line. None of the other suggestions in this thread made any > difference. > Thanks - that worked. And as you report, none of the other suggestions did. The following problem I can work around, but I mention because it is weird. When I go back and add -i or --interactive to zshdb, the completion menu comes in the line before rather than after, but what is more troublesome is that the entered text after the prompt isn't cleared. So, for input: zshdb<1> set hi instead of: highlight history zshdb<1> set highight I get: zshdb<1> set hiset highlight highlight history Some more info which may be relevant. I tried to reproduce this in that little 12 line program by adding the relevant code that I am using: completer() { ((2 == CURRENT)) && compadd -- fee fie foo } zle -C test_complete menu-expand-or-complete completer bindkey '^i' test_complete That works fine. It seems to have to do with the fact that in order to make sure in zshdb that I have an interactive terminal I open a new one. So I'm guessing that has something to do with the behavior above. --047d7bb04002bf333b050a4d5d63--