From: "Arsen Arsenović via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists" <emacs-tangents@gnu.org>
To: rms@gnu.org
Cc: brickviking@gmail.com, sbaugh@catern.com, luangruo@yahoo.com,
emacs-tangents@gnu.org
Subject: Re: [OT] Not clobbering bash history
Date: Thu, 07 Dec 2023 14:06:38 +0100 [thread overview]
Message-ID: <874jgub1gn.fsf@aarsen.me> (raw)
In-Reply-To: <E1rB4Rk-0005uI-Ct@fencepost.gnu.org>
[-- Attachment #1.1: Type: text/plain, Size: 2131 bytes --]
Richard Stallman <rms@gnu.org> writes:
> [[[ To any NSA and FBI agents reading my email: please consider ]]]
> [[[ whether defending the US Constitution against all enemies, ]]]
> [[[ foreign or domestic, requires you to follow Snowden's example. ]]]
>
> I moved this to emacs-tangents because thus isn't really about Emacs,
> but I don't know of a Bash list to use. Is there one?
IIRC there's bug-bash and it accepts patches, so it is perhaps also
appropriate for topics like this one.
> > Say that the history has eight entries, and a ninth was added by a
> > parallel process, the current process would be at the point after the
> > eighth element and should continue reading from there next time it wants
> > a history entry.
>
> Are you saying that multiple Bash processes in parallel should share
> one single history, which would contain all the commands the user
> entered in any of these processes?
Yes. Opinions vary on this, but I have a workflow which relies on this
(via a hack I put in my bashrc and found ages ago).
> So the commands of Basb process A and those of Basb process B would be
> interspersed in the history? And as you go forward and back in the
> history in Bash process B, you would see A's commands and B's commands
> in chronological order?
Yes. ZSH does implement this well IME (but I haven't used ZSH
extensively.. so I'm not sure if I'd run into trouble with it).
> That makes a kind of sense, but what I would envision is that each
> Bash process has its own history with only the commands of that process.
Some do prefer that. It'd be reasonable to do that by default, as it's
currently the default.
> Why do you prefer the shared history file approach
> to the one-history-per-process approach?
Because I rely on working in many, many interactive shells in parallel.
Though, on that note, it is perhaps reasonable to flip 'histappend' to
on by default, even if nothing else changes (because otherwise history
is lost since only the last shells history is kept).
Thanks, have a lovely day.
--
Arsen Arsenović
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 251 bytes --]
[-- Attachment #2: Type: text/plain, Size: 92 bytes --]
---
via emacs-tangents mailing list (https://lists.gnu.org/mailman/listinfo/emacs-tangents)
next prev parent reply other threads:[~2023-12-07 13:06 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <87wmufm7r7.fsf@catern.com>
[not found] ` <87fs12jkik.fsf@yahoo.com>
[not found] ` <d858823d-d95a-1865-7331-671e3fa6b4e4@gutov.dev>
[not found] ` <s0d34x1q050.fsf@yahoo.com>
[not found] ` <87ttphlqlo.fsf@catern.com>
[not found] ` <CAHWye8693z4hSJgEosPH9_ZrH88F5dbWXPS78EdfeT393FYG7g@mail.gmail.com>
[not found] ` <E1r5dUV-00019J-Gz@fencepost.gnu.org>
[not found] ` <87v89ujwa6.fsf@aarsen.me>
2023-11-22 20:43 ` [OT] Not clobbering bash history Jens Schmidt via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists
2023-11-22 21:50 ` Arsen Arsenović via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists
2023-11-23 12:42 ` Spencer Baugh
2023-11-23 20:12 ` Jens Schmidt via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists
[not found] ` <E1r6isT-000665-Pt@fencepost.gnu.org>
[not found] ` <86il5g9qs9.fsf@aarsen.me>
[not found] ` <E1r9zM4-000405-Gg@fencepost.gnu.org>
[not found] ` <864jgy85g5.fsf@aarsen.me>
2023-12-07 2:49 ` Richard Stallman
2023-12-07 5:34 ` mbork
2023-12-07 5:48 ` Emanuel Berg
2023-12-07 9:34 ` mbork
2023-12-07 5:52 ` Yuri Khan
2023-12-07 6:22 ` Emanuel Berg
2023-12-07 6:44 ` Jean Louis
2023-12-11 12:09 ` Arsen Arsenović via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists
2023-12-07 13:06 ` Arsen Arsenović via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists [this message]
2023-12-08 3:56 ` Richard Stallman
2023-12-08 10:15 ` Arsen Arsenović via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists
2023-12-08 3:54 ` Richard Stallman
2023-12-08 6:22 ` brickviking
2023-12-08 10:13 ` Arsen Arsenović via Emacs news and miscellaneous discussions outside the scope of other Emacs mailing lists
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874jgub1gn.fsf@aarsen.me \
--to=emacs-tangents@gnu.org \
--cc=arsen@aarsen.me \
--cc=brickviking@gmail.com \
--cc=luangruo@yahoo.com \
--cc=rms@gnu.org \
--cc=sbaugh@catern.com \
/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.
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 read-only IMAP folder(s) and NNTP newsgroup(s).