10 Commits
Author SHA1 Message Date
Dabezt 0b44dd5a48 Make trash.swift safer and more modern 2021-12-31 14:07:42 +03:00
Dabezt e4f106533e Modernize quarantine.swift 2021-12-31 13:23:45 +03:00
XuehaiPan 3f96d963f7 style: fix inconsistent code style for shell scripts 2021-09-15 14:59:01 +08:00
Markus Reiter 5aa0dbe1f9 Move RMDIR_SH into separate file. 2021-04-02 03:01:08 +02:00
Markus Reiter 04493e2dde Fix trash.swift without arguments. 2019-10-23 06:59:39 +02:00
L. E. Segovia f980ac82b9 Cask: refuse to trash root-owned files
These files cannot be trashed from CLI without sudo, which trashes them
instead to root's Trash. AppleScript isn't of use here because it will
break Travis (as it will fail when asking for admin permissions).

Fixes homebrew/homebrew-cask#69897
2019-10-01 11:12:23 +00:00
L. E. Segovia 93b2c29612 Port file trashing to Swift
This avoids hitting AppleScript timeouts in CI.
2019-05-09 20:03:31 +00:00
L. E. Segovia ed6f2829b1 Cask: check support of quarantine's tools
- In some cases (usually old CLT versions) Swift is available but needs an
extra guard to use the quarantine API.
- xattr's native filesystem recursion is an Apple extension which is
not available in Mojave; so let's use xargs.
- Insert a quarantine support check in brew cask doctor.

Fixes Homebrew/homebrew-cask#51554, and fixes Homebrew/homebrew-cask#51538.
2018-09-04 21:11:29 +00:00
Mike McQuaid e06f8a8beb Rename Homebrew-Cask to Homebrew Cask. 2018-09-04 09:56:57 +01:00
Mike McQuaid 90b3a13909 cask: move cask/lib/hbc/* to cask/*.
Fix the load path, requires and some filenames accordingly.
2018-09-04 09:56:57 +01:00