Latest LQ Deal: Latest LQ Deals
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 06-19-2003, 04:15 PM   #1
Registered: Apr 2003
Posts: 87

Rep: Reputation: 15
bash scripting - how long ago file was modified

Is there a way to grab how long ago a file was modified?
Old 06-19-2003, 04:41 PM   #2
Registered: Jan 2003
Location: Connecticut, US
Distribution: Red Hat 9.0
Posts: 98

Rep: Reputation: 15
'man stat'

# stat foo
# stat -t foo

I know this works, but there may well be a better way.
Old 06-19-2003, 04:42 PM   #3
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 67
Take a look at "stat".
Old 06-19-2003, 05:10 PM   #4
Registered: Apr 2003
Posts: 87

Original Poster
Rep: Reputation: 15
Thanks, it works.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Bash Scripting Empty file john8675309 Linux - Software 2 08-08-2007 05:05 PM
Problems with Fat long file names in Bash brett90 Slackware 5 06-03-2005 01:15 PM
bash scripting - how to make config file? Neorio Programming 3 10-22-2004 07:39 AM
bash scripting read from file cadj Programming 2 02-29-2004 11:42 PM
bash scripting - largest # file extension brian0918 Programming 3 06-16-2003 01:06 PM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:02 AM.

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