{"id":1261,"date":"2016-04-05T09:28:42","date_gmt":"2016-04-05T13:28:42","guid":{"rendered":"http:\/\/linux.uits.uconn.edu\/?p=310"},"modified":"2016-04-05T09:28:42","modified_gmt":"2016-04-05T13:28:42","slug":"timestamping-your-bash_history","status":"publish","type":"post","link":"https:\/\/technicalknow-how.com\/wp\/timestamping-your-bash_history\/","title":{"rendered":"Timestamping your bash_history"},"content":{"rendered":"<p>I use this all the time and occasionally find a server that isn&#8217;t configured to timestamp the bash_history. It seemed like something I should preserve here for future reference.<\/p>\n<p>Adding a timestamp is really simple, just execute the following:<\/p>\n<p>echo &#8216;export HISTTIMEFORMAT=&#8221;%d\/%m\/%y %T &#8220;&#8216; &gt;&gt; ~\/.bash_profile ; source ~\/.bash_profile<\/p>\n<p>That&#8217;s it, now the history command is more useful.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I use this all the time and occasionally find a server that isn&#8217;t configured to timestamp the bash_history. It seemed like something I should preserve here for future reference. Adding a timestamp is really simple, just execute the following: echo &#8216;export HISTTIMEFORMAT=&#8221;%d\/%m\/%y %T &#8220;&#8216; &gt;&gt; ~\/.bash_profile ; source ~\/.bash_profile That&#8217;s it, now the history command [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"wds_primary_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false},"version":2}},"categories":[75,148],"tags":[201,221,202,141],"class_list":["post-1261","post","type-post","status-publish","format-standard","hentry","category-bash","category-system-administration","tag-bash","tag-documentation","tag-history","tag-system-administration"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p3749z-kl","_links":{"self":[{"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/posts\/1261"}],"collection":[{"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/comments?post=1261"}],"version-history":[{"count":0,"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/posts\/1261\/revisions"}],"wp:attachment":[{"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/media?parent=1261"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/categories?post=1261"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/technicalknow-how.com\/wp\/wp-json\/wp\/v2\/tags?post=1261"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}