0

私は完全な AppleScript の処女であり、同じ名前の異なるフレームワークを使用する同じアプリケーションの 2 つのバージョンがあります。

フレームワークの正しいバージョンをフレームワーク フォルダーに移動する 2 つのスクリプトを作成して、デスクトップからすばやく交換できるようにしようとしています。

これは私がこれまでに持っているものですが、AppleEvent Handler failed -10000 エラーをスローしています。

tell application "Finder"
    duplicate POSIX file "Machintosh HD/Framework Store/Test.framework" to POSIX file "Machintosh HD/Library/Frameworks/Test.framework" with replacing
end tell

誰かが私が間違っているところを指摘できますか?

どんな助けでも大歓迎です。

4

2 に答える 2

0

Had ディスク名もあることに気付きました。それを参照する必要があるのは、最初のスラッシュ「/」だけです。

 tell application "Finder"
    set rootFolder to POSIX file "/Framework Store/Test.framework"
    set targetFolder to POSIX file "/Library/Frameworks/"
        duplicate rootFolder to targetFolder with replacing
  end tell
于 2013-04-24T14:04:15.543 に答える
0

試す:

tell application "Finder"
    duplicate POSIX file "Machintosh HD/Framework Store/Test.framework" to POSIX file "Machintosh HD/Library/Frameworks" with replacing
end tell
于 2013-04-23T17:24:11.827 に答える