Adjust the rules based on the current codebase. Remove various enable,
disables and default values that are unnecessary. Add more comments
explaining why. Make minor changes needed to enable a few more rules.
We want to be able to test the raise functionality without
monkey-patching #raise on every object in the system, which is one of
the side effects of loading debrew.rb.
If the debugger's monkey-patched raise was passed an instantiated
exception, the #exception method was called with a potentially nil
argument, causing its instance data to be thrown away. This hides
potentially useful information from the user.
Fix it by allowing instantiated exceptions to be reraised unharmed.
FixesHomebrew/homebrew#17622.
Only limited debugging functionality is available to things that involve
the Readline formula, but it is better than crashing outright.
c.f. Homebrew/homebrew#15776.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
A new feature for easing the pain of working with complex formulas, or
formulas for large packages. When running brew in debug mode (-d), if an
exception propagates outside the formula's install method, you now get a menu
which lets you return to the point where the exception was raised and perfom
several useful actions, such as:
- printing a backtrace
- entering IRB to examine the context and test ruby code
- entering the debugger (if ruby-debug is available)
- entering a shell
- ignoring the exception or proceeding with the raise as normal
Signed-off-by: Max Howell <mxcl@me.com>
* Fixed conflict in build.rb.
* Removed old debug handling in Formula.brew.
ClosesHomebrew/homebrew#10435.