Hi
Can anyone help with a macro to move an app, selected in Finder, to /Applications and then opening it (preferably it should do a 'right-click open' as to bypass Gatekeeper)?
Thanks
Martin
Hi
Can anyone help with a macro to move an app, selected in Finder, to /Applications and then opening it (preferably it should do a 'right-click open' as to bypass Gatekeeper)?
Thanks
Martin
Hey Martin,
That’s not too difficult. Try this in an Execute AppleScript Action:
set appFolder to path to applications folder from system domain
tell application "Finder" to set finderSel to selection as alias list
if length of finderSel = 1 then
set appPath to POSIX path of item 1 of finderSel
set shCMD to text 2 thru -1 of "
xattr -d com.apple.quarantine " & quoted form of appPath & " ; exit 0"
do shell script shCMD
end if
tell application "Finder"
move finderSel to appFolder
open finderSel
end tell
-Chris
When I run your AppleScript from a KM macro nothing happens. When I run it from Script Editor I get this:
error “xattr: /Users/Carl/Desktop/Alarm Clock.app/: No such xattr: com.apple.quarantine” number 1
Carl
Hey Carl,
Try the edited version (same post).
-Chris
Great! Thanks Chris.
Carl
Thanks a lot Chris, it works perfectly