Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Finding the first history event of the current instance



On May 29,  5:16pm, Bart Schaefer wrote:
} Subject: Re: Finding the first history event of the current instance
}
} On May 23,  4:22pm, Christian Neukirchen wrote:
} }
} } How can I list *only* the history lines that I typed into the current
} } session?
} 
} Or there's this patch.  I didn't add an option for listing only the
} NON-local history, but it should be pretty obvious how to do so.

Hmm, except I've just realized that lines read from $HISTFILE are taken
to be local to the current shell when they are loaded at startup, We
would need to filter for the HIST_OLD flag instead of HIST_FOREIGN to
get just those lines entered interactively, and I'm not sure how that
interacts with INC_APPEND_HISTORY -- do the events become "old" as soon
as they are appended to the file?

The options -N (new), -O (old), and -F (foreign) are all currently unused
by "fc" if we wanted to add multiple filterings.

Anyway, sorry, but the patch as it stands does not actually solve the
original problem.



Messages sorted by: Reverse Date, Date, Thread, Author