abstract_uninstall: add timeout to trash_paths
This commit is contained in:
parent
d6bd271986
commit
1406ee7eac
@ -324,6 +324,8 @@ module Cask
|
|||||||
set item i of argv to (item i of argv as POSIX file)
|
set item i of argv to (item i of argv as POSIX file)
|
||||||
end repeat
|
end repeat
|
||||||
|
|
||||||
|
try
|
||||||
|
with timeout of 30 seconds
|
||||||
tell application "Finder"
|
tell application "Finder"
|
||||||
set trashedItems to (move argv to trash)
|
set trashedItems to (move argv to trash)
|
||||||
set output to ""
|
set output to ""
|
||||||
@ -338,6 +340,11 @@ module Cask
|
|||||||
|
|
||||||
return output
|
return output
|
||||||
end tell
|
end tell
|
||||||
|
end timeout
|
||||||
|
on error
|
||||||
|
-- Ignore errors (probably running under Azure)
|
||||||
|
return 0
|
||||||
|
end try
|
||||||
end run
|
end run
|
||||||
APPLESCRIPT
|
APPLESCRIPT
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user