POSIX paths query explained better
POSIX paths query explained better
- Subject: POSIX paths query explained better
- From: Steve Thompson <email@hidden>
- Date: Wed, 8 Oct 2003 17:03:25 +0100
After thinking about this, I now know why it doesn't work but I still
can't find out how to work around it. Obviously (I think) the Finder
doesn't understand POSIX paths. Which is why it says the file doesn't
exist. So I assume I have to do some shell script to find out if the
file exists (as explained in an earlier mail on a different subject,
"Server" is my test box - when my script is finished the server will be
a RH Linux box connected as an NFS share so I will have to check
existence of files such as /private/mnt/database/layouts/thing.eps).
So, what I need is a way of doing "exists" on a volume that isn't
mounted in the Finder. Can someone point me in the right direction? I
suppose I could do a 'ls' of the directory as a shell script and see if
the file name is in the resulting text, but is there a tidier way to do
it?
Thanks,
Steve
On Wednesday, October 8, 2003, at 04:23 pm, Steve Thompson wrote:
I have this script:
set temp to "Server:Master Database:to be Databased:AUGUST IMAGE
UPLOADS - No17:layouts:161999-Image.eps"
set test to quoted form of POSIX path of (temp)
tell application "Finder"
exists file temp
exists file test
end tell
And the output is
tell application "Finder"
exists file "Server:Master Database:to be Databased:AUGUST IMAGE
UPLOADS - No17:layouts:161999-Image.eps"
--> true
exists file "'/Volumes/Server/Master Database/to be Databased/AUGUST
IMAGE UPLOADS - No17/layouts/161999-Image.eps'"
--> false
end tell
So it exists in HFS format but not in POSIX format. Can anyone explain
to me why that is and how to stop it? I need to check if the file
exists on this server (mounted as an NFS volume) before I ditto a file
on to it, purely to save time (don't want to copy a file if it's
already there as it's over an slow DSL line).
Thanks,
Steve
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.