zsh-users
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: Ray Andrews <rayandrews@eastlink.ca>
Cc: Zsh Users <zsh-users@zsh.org>
Subject: Re: combining .histfiles
Date: Tue, 14 Oct 2014 16:55:53 -0700	[thread overview]
Message-ID: <CAH+w=7Z64LON=WS7QHahqU8uLYd__9PT0eHFWDLqgTE7+YRUtA@mail.gmail.com> (raw)
In-Reply-To: <543DA2E0.8020000@eastlink.ca>

[-- Attachment #1: Type: text/plain, Size: 1131 bytes --]

On Oct 14, 2014 3:24 PM, "Ray Andrews" <rayandrews@eastlink.ca> wrote:
>
> I could stop the command on each line  individually,  but not the
.histfile *itself*.  Is there some way to
> to break out of it?

As I said, Ctrl+c should do it.  I just now manufactured a file with a few
hundred "cp largefile /dev/null" commands, read it with "." and was able to
end it with Ctrl+c before it made it all the way through.

Of course if the history file contains a command to trap or otherwise
disable tty interrupts, you're stuck once that is reached.  Ctrl+z will
only suspend the current command, not the whole script.

Incidentally the reason the file format is that way is so that it can be
shared with other (non-zsh) shells if desired.  That's probably not very
often desired any more.

It occurs to me that it might be feasible to ensure that the first line of
the history file is always "return 1".  There'd be some potential user
confusion to dispel ("why is my history file 101 lines long when I have
SAVEHIST set to 100?").  On the other hand, you are the first person I've
ever heard of make this particular mistake.  :-) :-/

  reply	other threads:[~2014-10-14 23:56 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-11 18:53 zsh 5.0.7 Ray Andrews
2014-10-11 20:10 ` Bart Schaefer
2014-10-11 21:46   ` Ray Andrews
2014-10-11 21:56     ` Axel Beckert
2014-10-11 22:43       ` Ray Andrews
2014-10-11 22:01     ` Bart Schaefer
2014-10-12  0:29       ` Ray Andrews
2014-10-13 19:02         ` Greg Klanderman
2014-10-13 22:04           ` Ray Andrews
2014-10-13 22:58             ` Greg Klanderman
2014-10-14  1:17               ` Ray Andrews
2014-10-14 20:12                 ` Greg Klanderman
2014-10-14 20:33                   ` Ray Andrews
2014-10-14 17:20             ` combining .histfiles Ray Andrews
2014-10-14 22:04               ` Bart Schaefer
2014-10-14 22:25                 ` Ray Andrews
2014-10-14 23:55                   ` Bart Schaefer [this message]
2014-10-15  1:02                     ` Ray Andrews
2014-10-15  1:09                       ` Kurtis Rader
2014-10-15  1:25                         ` Ray Andrews
2014-10-23  2:58             ` c++ comments Ray Andrews
2014-10-23  4:41               ` Bart Schaefer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAH+w=7Z64LON=WS7QHahqU8uLYd__9PT0eHFWDLqgTE7+YRUtA@mail.gmail.com' \
    --to=schaefer@brasslantern.com \
    --cc=rayandrews@eastlink.ca \
    --cc=zsh-users@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).