- tar -N
- Posted by ivan danicic on July 5th, 2003
Hello All, I want to archive only the files with date after some-day. If I
do
tar -cvf...bla.tar -N '02-June-03' .
it also archives some april files, whatever format I use for the date, e.g.
20030702.
Any comments and hints will be appreciated.
Ivan
- Posted by Gary Desrosiers on July 5th, 2003
ivan danicic wrote:
Seems that tar is working off the /last modified/ date not the creation
date. The documentation would have you believe otherwise.
This backed up all files that were /modified/ after July 4th, 2003:
tar -N 2003-07-04 -cvf save.tar .
Gary
--
echo $EMAIL_ADDRESS|sed -e "s/nosp/gtd0/;s/0am/esrosi/"
- Posted by Michael Buchenrieder on July 6th, 2003
Gary Desrosiers <nospam@cox.net> writes:
Of course. There's nothing like "creation date" on a standard UN*X
filesystem; this data is never preserved at all. And why should it?
What you _want_ is the time a file has been modified for to be
able to determine which file's status has been changed since the
last time you checked it. If - for some mysterious reasons -
you really need to know the creation time, you'll have to create files
with the needed data appended to the filename or use similar approaches.
Michael
--
Michael Buchenrieder * mibu@scrum.greenie.muc.de * http://www.muc.de/~mibu
Lumber Cartel Unit #456 (TINLC) & Official Netscum
Note: If you want me to send you email, don't munge your address.
- Posted by Peter T. Breuer on July 6th, 2003
ivan danicic <ivand@blueyonder.co.uk> wrote:
What are you talking about? You have posted in the wrong place, without
reference to the quote you are talking about (in your own mind!) so I
cannot understand you! Please rectify your post .. I'll place your
words below where I THINK you might have intended them to go, but
please do this for yourself!
What do you not understand about that? the MODIFICATION date is the
only possible interpretation of what the documentation talks about, for
the reason given. Did you not understand the reason? SAY!
But I have TOLD you! What is your comprehension difficulty? Why do you
post so incomprehensibly? It's annoying!
Which is precisely what it does. If you want to get a clue as to what
dates are associated with a file in unix, man ls, /modif, /change.
Peter
- Posted by ivan danicic on July 6th, 2003
Peter T. Breuer wrote:
as well as all subdirectory files.
Ivanls -lt:
total 5793
-rw-r--r-- 1 ivie users 2132 Jul 6 14:22 tmp
drwxr-xr-x 2 ivie users 184 Jul 6 14:21 moretests
-rw-r--r-- 1 ivie users 2027 Jul 5 16:04 emacstest.log
-rw-r--r-- 1 ivie users 2938880 Jul 4 18:13 test3.tar
-rw-r--r-- 1 ivie users 662 Jul 3 21:52 texput.log
-rw-r--r-- 1 ivie users 10240 Jul 3 21:47 test2.tar
-rw-r--r-- 1 ivie users 10240 Jul 3 19:09 test.tar
-rw-r--r-- 1 ivie users 8 Jul 2 12:16 emacstest.aux
-rw-r--r-- 1 ivie users 8 Apr 8 12:21 emacstest3.aux
-rw-r--r-- 1 ivie users 288 Apr 8 12:21 emacstest3.dvi
-rw-r--r-- 1 ivie users 1848 Apr 8 12:21 emacstest3.log
-rw-r--r-- 1 ivie users 100 Apr 8 12:21 emacstest3.tex
-rw-r--r-- 1 ivie users 962 Apr 8 10:57 emacsdemo
-rw-r--r-- 1 ivie users 811 Apr 8 10:53 emacsdemo~
-rw-r--r-- 1 ivie users 99 Apr 8 10:43 emacstest3.tex~
-rw-r--r-- 1 ivie users 50 Apr 8 10:41 inputtest.tex
-rw-r--r-- 1 ivie users 8 Apr 8 10:34 emacstest2.aux
-rw-r--r-- 1 ivie users 412 Apr 8 10:34 emacstest2.dvi
-rw-r--r-- 1 ivie users 2029 Apr 8 10:34 emacstest2.log
-rw-r--r-- 1 ivie users 165 Apr 8 10:34 emacstest2.tex
-rw-r--r-- 1 ivie users 171 Apr 8 10:34 emacstest2.tex~
-rw-r--r-- 1 ivie users 412 Apr 8 10:33 emacstest.dvi
-rw-r--r-- 1 ivie users 165 Apr 8 10:33 emacstest.tex
-rw-r--r-- 1 ivie users 154 Apr 7 20:33 emacstest.tex~
-rw-r--r-- 1 ivie users 346 Nov 28 2002 usesilly.class
-rw-r--r-- 1 ivie users 406 Nov 28 2002 usesilly.java
-rw-r--r-- 1 ivie users 132 Nov 27 2002 usesilly.java~
-rw-r--r-- 1 ivie users 1495040 Nov 9 2002 newer.tar
-rw-r--r-- 1 ivie users 1322816 Nov 8 2002 updatetest
-rw-r--r-- 1 ivie users 10240 Nov 8 2002 new.tar
-rw-r--r-- 1 ivie users 18 Nov 8 2002 alpha
-rw-r--r-- 1 ivie users 5 Nov 8 2002 beta
-rw-r--r-- 1 ivie users 6 Nov 7 2002 plop2
-rw-r--r-- 1 ivie users 13 Nov 7 2002 plop
drwxr-xr-x 2 ivie users 376 Nov 3 2002 latex2htmltest
-rw-r--r-- 1 ivie users 95 Nov 3 2002 latex2htmltest.aux
-rw-r--r-- 1 ivie users 592 Nov 3 2002 latex2htmltest.dvi
-rw-r--r-- 1 ivie users 1876 Nov 3 2002 latex2htmltest.log
-rw-r--r-- 1 ivie users 326 Nov 3 2002 latex2htmltest.tex
-rw-r--r-- 1 ivie users 301 Nov 3 2002 latex2htmltest.tex~
tar -N 2003-05-15 -cvf moretests/result.tar .
tar -tvf moretests/result.tar . :
drwxr-xr-x ivie/users 0 2003-07-06 14:27:48 ./
-rw-r--r-- ivie/users 2132 2003-07-06 14:22:43 ./tmp
-rw-r--r-- ivie/users 8 2003-04-08 10:34:58 ./emacstest2.aux
-rw-r--r-- ivie/users 412 2003-04-08 10:34:58 ./emacstest2.dvi
-rw-r--r-- ivie/users 2029 2003-04-08 10:34:58 ./emacstest2.log
-rw-r--r-- ivie/users 165 2003-04-08 10:34:58 ./emacstest2.tex
-rw-r--r-- ivie/users 8 2003-04-08 12:21:18 ./emacstest3.aux
-rw-r--r-- ivie/users 288 2003-04-08 12:21:18 ./emacstest3.dvi
-rw-r--r-- ivie/users 1848 2003-04-08 12:21:18 ./emacstest3.log
-rw-r--r-- ivie/users 100 2003-04-08 12:21:18 ./emacstest3.tex
-rw-r--r-- ivie/users 154 2003-04-07 20:33:35 ./emacstest.tex~
-rw-r--r-- ivie/users 10240 2003-07-03 19:09:43 ./test.tar
-rw-r--r-- ivie/users 2942 2003-07-06 14:28:31 ./tarresult
drwxr-xr-x ivie/users 0 2003-07-06 14:28:31 ./moretests/
-rw-r--r-- ivie/users 11970560 2003-07-06 14:21:49 ./moretests/ivie.tar
-rw-r--r-- ivie/users 18 2002-11-08 11:42:04 ./moretests/alpha
-rw-r--r-- ivie/users 2990080 2003-07-05 10:33:00 ./moretests/test3.tar
-rw-r--r-- ivie/users 5990400 2003-07-05 16:18:03 ./moretests/tests.tar
drwxr-xr-x ivie/users 0 2002-11-03 14:37:55 ./latex2htmltest/
-rw-r--r-- ivie/users 8 2003-07-02 12:16:18 ./emacstest.aux
-rw-r--r-- ivie/users 412 2003-04-08 10:33:12 ./emacstest.dvi
-rw-r--r-- ivie/users 2027 2003-07-05 16:04:45 ./emacstest.log
-rw-r--r-- ivie/users 165 2003-04-08 10:33:12 ./emacstest.tex
-rw-r--r-- ivie/users 662 2003-07-03 21:52:51 ./texput.log
-rw-r--r-- ivie/users 10240 2003-07-03 21:47:40 ./test2.tar
-rw-r--r-- ivie/users 2938880 2003-07-04 18:13:39 ./test3.tar
-rw-r--r-- ivie/users 171 2003-04-08 10:34:32 ./emacstest2.tex~
-rw-r--r-- ivie/users 99 2003-04-08 10:43:50 ./emacstest3.tex~
- Posted by Peter T. Breuer on July 6th, 2003
ivan danicic <ivand@blueyonder.co.uk> wrote:
Your date format is wrong. You have asked for files newer than the 7th
of April.
Peter
- Posted by Ed Murphy on July 6th, 2003
On Sun, 06 Jul 2003 17:31:26 +0200, Peter T. Breuer wrote:
I suppose that makes sense, as the OP is in the UK. I would have
expected a computer in the UK to assume DD-MM-YYYY rather than
MM-DD-YYYY, but I wouldn't have expected it to assume YYYY-DD-MM
rather than YYYY-MM-DD.
The original post mentioned '02-June-03'. Ivan, did you pass that
literal text as an argument to tar, or did you pass digits-only
representations of it?
Are there any files newer than April 7 that *aren't* archived? If
so, then something stranger is going on.
- Posted by ivan danicic on July 6th, 2003
Ed Murphy <emurphy42@socal.rr.com> wrote in message
news
an.2003.07.06.17.47.24.756468@socal.rr.com.. .
2003-05-15. There are three April 8 files not archived: emacsdemo,
emacsdemo~ and inputtest.tex. Thanks for your interest.
Ivan.
- Posted by ivan danicic on July 6th, 2003
Michael Buchenrieder <mibu@scrum.muc.de> wrote in message
news:HHLoFq.Ist@scrum.muc.de...
Ivan