Re: Common History across Shell
- From: "Chris F.A. Johnson" <cfajohnson@xxxxxxxxx>
- Date: Tue, 10 Jul 2007 17:01:07 -0400
On 2007-07-10, quarkLore wrote:
AFAIK history in bash is implemented such that each bash instance
maintains its individual history in memory. As and when a bash session
exits it updates history file.
If there are multiple shells running together then commands entered in
one can't be accessed using history command from other shells.
I am looking for a feature where if a user has multiple shells and on
a special keystroke / command all shells get a common history which is
sum of all histories.
Does such a feature exist in bash or any other shell?
Can such a feature be implemented without changing the shell's code?
PROMPT_COMMAND='history -a; history -c; history -r'
--
Chris F.A. Johnson, author <http://cfaj.freeshell.org/shell/>
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)
===== My code in this post, if any, assumes the POSIX locale
===== and is released under the GNU General Public Licence
.
- References:
- Common History across Shell
- From: quarkLore
- Common History across Shell
- Prev by Date: Re: tar extract write error
- Next by Date: cp the file content (with spaces)
- Previous by thread: Re: Common History across Shell
- Next by thread: Re: Common History across Shell
- Index(es):
Relevant Pages
|