Hi,
The osascript example in a recent thread gave me an idea - I'd like a
shell command that would tell the Finder to reveal the item with a
certain path, something like this:
% osascript -e 'tell application "Finder" to reveal file
"/Users/ken/Perl.tar"'
This would be useful (if it worked) for initiating drag-n-drop
operations, getting finder info, looking at the preview icon, etc.
I've tried several variations on the above theme, but none of them
work. My Applescript-Fu is not strong. For instance, the above gives
me the error:
execution error: Finder got an error: Can't get file
"/Users/ken/Perl.tar". (-1728)
If I dig around in the applescript dictionary for the Finder, I find a
'name' property, but that doesn't seem to get me much farther:
% osascript -e 'tell application "Finder" to reveal file name
"/Users/ken/Perl.tar"'
syntax error: Invalid key form. (-10002)
Anyone?
-Ken
- Re: [OT] More Terminal/Finder cooperation Ken Williams
- Re: [OT] More Terminal/Finder cooperation Ken Williams
- Re: [OT] More Terminal/Finder cooperation Bruce Van Allen
- Re: [OT] More Terminal/Finder cooperation Paul McCann
- Re: [OT] More Terminal/Finder cooperation Ken Williams
- Re: [Really OT] More Terminal/Finder coop... Jeremy Mates
- Re: [OT] More Terminal/Finder cooperation Peter N Lewis