History command with time stamp

Running the ‘ history ‘ command only gives you line numbers. Sometimes it’s useful to have a time stamp attached to each command to build a clearer picture.

Simply set the ” HISTTIMEFORMAT ” env variable to enable time stamps in ‘ history ‘.

Run the command below.

export HISTTIMEFORMAT=' %F %T '

Before:

After:

© 2008-2012 The Danesh Project
Powered by Wordpress and made by Guerrilla. Hosted at ServerFreak