Skip to content

Optional configure flag to flush history after each command? #10

@hugusmaximus

Description

@hugusmaximus

Hello,

I understand the current history behavior is conservative for compatibility and historical performance reasons (which made sense in the 1990s with slower disks and different workloads).

However, would it be acceptable to add an optional ./configure flag (e.g. --enable-immediate-history-flush) that makes interactive shells append to $HISTFILE after each executed command?

Today this requires PROMPT_COMMAND="history -a". A compile-time opt-in would preserve defaults while allowing crash-resilient history persistence on modern systems.

Would this be considered?

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions