Bash History Enable/Disable

  • Disable history for the current shell, doesn't affect other shells or future shells
set +o history
  • Clear the current command history
history -c
  • Permanently disable history
echo 'set +o history' >> ~/.bashrc

Leave a Reply

Your email address will not be published. Required fields are marked *