LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 01-06-2023, 02:15 PM   #1
sofasurfer
Member
 
Registered: Oct 2003
Posts: 252

Rep: Reputation: 20
What are the 10 digit numbers in my bashrc_history file


What are 10 digit numbers for every .bashrc_history entry. I never noticed this before even though I have accessed this history before. Maybe I changed something in .bashrc at one time. Anyway, what are these numbers for? They do not seem to be timestamps.
Code:
sudo apt install ranger
#1671403383
sudo apt install chromium
#1671408737
sudo apt-get install chromium-browser
#1671409949
sudo nautilux
#1671409956
 
Old 01-06-2023, 02:28 PM   #2
Turbocapitalist
LQ Guru
 
Registered: Apr 2005
Distribution: Linux Mint, Devuan, OpenBSD
Posts: 7,367
Blog Entries: 3

Rep: Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771Reputation: 3771
They are time stamps, but in the UNIX Epoch:

Code:
date -d '@1671403383'
See "man bash" in the paragraph HISTTIMEFORMAT under Shell Variables if you wish a different format.
Or see "man bash" in the section HISTORY for more details.
 
Old 01-06-2023, 02:35 PM   #3
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,793

Rep: Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952Reputation: 5952
They look like timestamps.
As of a few seconds ago. date +%s = 1673037106

Is HISTTIMEFORMAT variable set anywhere?

To late...
 
Old 01-06-2023, 04:00 PM   #4
sofasurfer
Member
 
Registered: Oct 2003
Posts: 252

Original Poster
Rep: Reputation: 20
Near as I can see the UNIX format is unchangeable in the /.bashrc file.

Last edited by sofasurfer; 01-07-2023 at 06:12 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Read digit by digit in variable pedropt Programming 6 12-25-2017 04:24 AM
[SOLVED] How to use sed command to delete lines only 1-3 digit numbers on a particular column? kahthiam Linux - Newbie 4 12-27-2011 07:41 AM
Substitue single-digit, two-digit, and 3-digit numbers with text using sed dmason165 Programming 13 08-07-2009 10:38 AM
[BASH] Search for 5-digit numbers in document General Programming 2 01-10-2007 08:06 PM
54 digit numbers Scratchit General 3 06-23-2004 09:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 04:38 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration