Re: Newbie Date questions
Re: Newbie Date questions
- Subject: Re: Newbie Date questions
- From: Doug McNutt <email@hidden>
- Date: Tue, 2 Mar 2010 10:07:55 -0700
At 07:11 +0100 3/2/10, ba95 wrote:
>MANY THANKS each and every one of you who responded to my elementary questions.
>
>Concerning my backup script problems, I have not clearly understood what I am supposed to do...
>
>As I wrote before, this script is based on modification dates comparison.
>It compares the source files modifications dates vs the backup files ones.
>If the backup files modifications dates are not updated by the finder, the result is not perfect.
>What could be the clear reliable solution ?
>
>Little nice snippet would be greatly appreciated.
Have a look at the UNIX cp (copy) tool, do "man cp" in Terminal.app, and pay attention to the -p option. With it you can ask cp to preserve the times and dates. For earlier versions of OS X you might need to use Apple's version of the tool, CpMac, to preserve resource forks.
You ought to find less helpful tools that will allow you to read out modified date/time values from files that are simple numbers with no formatting into calendar quantities. It's then easy to just compare the numbers. Bigger means newer. On another OS I use the "stat" command to show the last modification time among other things.
It's not alt all clear that AppleScript with Finder is the right tool for your task but the UNIX tools are all available with "do shell script".
--
--> In Christianity, man can have only one wife. This is known as monotony. <--
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden