diff options
| author | Xu Cheng | 2015-10-17 03:57:40 +0800 |
|---|---|---|
| committer | Xu Cheng | 2015-10-17 03:57:40 +0800 |
| commit | dee4c76e6257a71672e259c0ae1e3e5c62b86e78 (patch) | |
| tree | 03591073afdbd2cf72b60b1d7cd7d58622ab6fbf /Library | |
| parent | f81d561b67e2188b7fdd1cbb782cba00db08af2e (diff) | |
| download | brew-dee4c76e6257a71672e259c0ae1e3e5c62b86e78.tar.bz2 | |
uninstall: fix when Cellar doesn't exist
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/cmd/uninstall.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Library/Homebrew/cmd/uninstall.rb b/Library/Homebrew/cmd/uninstall.rb index 0dbdc08c4..f1d0ea636 100644 --- a/Library/Homebrew/cmd/uninstall.rb +++ b/Library/Homebrew/cmd/uninstall.rb @@ -46,9 +46,11 @@ module Homebrew ensure # If we delete Cellar/newname, then Cellar/oldname symlink # can become broken and we have to remove it. + if HOMEBREW_CELLAR.directory? HOMEBREW_CELLAR.children.each do |rack| rack.unlink if rack.symlink? && !rack.resolved_path_exists? end + end end def rm_pin(rack) |
