history -a

From wikieduonline
Revision as of 14:30, 25 January 2024 by Welcome (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

-a	append history lines from this session to the history file
history -a; ls -al ~/.bash_history


Save every executed command to: ~/.bash_history

export PROMPT_COMMAND='history -a'

Related

history -c
history -r

See also

Advertising: