Created
May 15, 2012 01:54
-
-
Save joshenders/2698491 to your computer and use it in GitHub Desktop.
environment variables relating to .bash_history
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Unset bounds on history file. Disk is cheap, unlimited is fine until it's not | |
# and then rotate | |
export HISTFILESIZE= | |
export HISTSIZE= | |
# Add timestamps to .bash_history | |
# TODO: find someway to store the current working directory for forensics | |
export HISTTIMEFORMAT="%d/%m/%y %T " | |
# The "ignoreboth" setting ignores repeated lines as well as silently discards | |
# lines beginning with a space for privacy. Equivalent to 'ignoredups' and | |
# 'ignorespace' | |
export HISTCONTROL=ignoreboth | |
# Commands to not log in history | |
export HISTIGNORE=ls:cd | |
# If set, the history list is appended to the file named by the value of the | |
# HISTFILE variable when the shell exits, rather than overwriting the file. | |
shopt -s histappend |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment