-
-
Notifications
You must be signed in to change notification settings - Fork 12.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
*formulae: Avoid using rm_rf
, rm_f
or rmtree
#177331
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks right!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should probably be a bit more careful about the ones in post_install
blocks, as those will be disruptive to more users.
Two comments:
|
For formulae, it might be an idea to just change We do module SafeFileUtils
include FileUtils
def rm_f(*)
...
end
end
class Formula
include SafeFileUtils
...
end Which can be used in (Not saying we need to do this: just tabling options) |
I think these differences should be covered with
This would still be a breaking change. I think it'd be nicer to introduce a new method/API if we're going to do that rather than shadowing the |
1533169
to
f3f4938
Compare
I re-generated this after the latest changes to the RuboCop. |
Hmmm. I'll bunch these in smaller batches, and test installing and testing each one locally. :-) |
HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>
, where<formula>
is the name of the formula you're submitting?brew test <formula>
, where<formula>
is the name of the formula you're submitting?brew audit --strict <formula>
(after doingHOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>
)? If this is a new formula, does it passbrew audit --new <formula>
?rm_f
andrm_rf
in formulae and casks brew#17705.