| Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
But remove some manual `.freeze`s on constants that shouldn't be
constants.
|
|
|
|
|
|
Part of #567
|
|
|
|
|
|
Fixes the case where I have `mysql56` installed but do
`brew uninstall foo/bar/mysql56` which isn't a valid formula.
Fixes https://github.com/Homebrew/legacy-homebrew/issues/39883.
|
|
If we try to call `Formulary.from_keg(f, :head)` on the keg that
is not HEAD-keg itself, we don't need to update commit of
returned formula and should use just HEAD version with nil commit.
Same is true for `ARGV.resolved_formulae`
|
|
|
|
|
|
|
|
|
|
Prior to this change there were only 3 instances of `STD(IN|OUT|ERR)`
versus 74 instances of `$std(in|out|err)` in the Homebrew code base. The
latter variant is also strongly suggested by bbatsov's Ruby Style Guide.
|
|
This means that we do not need to read formulae or evaluate Ruby at
upload time.
|
|
|
|
|
|
Present a more helpful error message if a formula file was loaded, but
the class(es) therein didn't match the expected formula class name.
|
|
Also make `Homebrew/homebrew` as an alias of this tap to keep
backward compatibility.
|
|
Core tap will be separated from core code in the near future.
It makes sense to rename it to CoreTap.
|
|
formula_rename and tap_migrations are now handled inside Tap.
Closes Homebrew/homebrew#49549.
Signed-off-by: Xu Cheng <xucheng@me.com>
|
|
* Use `Tap#formula_dir` instead of `Tap#formula_files` to find formula
file to have better performance and avoid caching issue.
* Change the loader logic to search name -> search alias -> search old name.
This is more consistence with what we do when loading core formula
file.
Closes Homebrew/homebrew#49484.
Signed-off-by: Xu Cheng <xucheng@me.com>
|
|
For users whose local brew is at around 2015-06-11 to 2015-08-06,
running `brew update` will emit following error:
Error: uninitialized constant Formulary::CoreFormulaRepository
This is caused by the same bug described in Homebrew/homebrew#42553.
This commit workarounds this issue and restores `brew update` compatibility
for users mentioned above.
Also cleanup legacy `require "cmd/tap"`.
|
|
Let's hide implementation detail on where to find core formulae alias
directory. This will benefit future core code and formulae separation.
|
|
Fixes Homebrew/homebrew#46984.
|
|
|
|
|
|
|
|
|
|
Closes Homebrew/homebrew#46537.
Signed-off-by: Xu Cheng <xucheng@me.com>
|
|
The flow is as follow:
* If tap is nil(DIY install), search using name.
* If tap is found, search using full name.
* If tap is found and full name searching failed, search using name.
This usually means the formula may be migrated to different tap.
Closes Homebrew/homebrew#44771.
Signed-off-by: Xu Cheng <xucheng@me.com>
|
|
There are plenty of IO operations inside Tap object, and it will be more
when implementing formula alias reverse look up(e.g. list all of alias
names for a formula). So let's cache them.
Some benchmark:
$ time brew info $(brew ruby -e 'puts Formula.tap_names') > /dev/null
Before: 6.40s user 2.42s system 96% cpu 9.134 total
After: 4.75s user 0.77s system 97% cpu 5.637 total
Closes Homebrew/homebrew#44377.
Signed-off-by: Xu Cheng <xucheng@me.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Closes Homebrew/homebrew#42743.
Signed-off-by: Xu Cheng <xucheng@me.com>
|
|
Everything that used HOMEBREW_CELLAR/canonical_name
could point to something that doesn't exist because
loader_for tries to load new name formula if no old
name found. However there can be software installed
from path with the same name that renamed formulae
had and we still need to link/unlink/uninstall etc
that software. The solution is Formulary#to_rack
method that returns rack for given name.
- Add Formulary#to_rack
- Update ARGV.kegs
- Update cmd/switch
|
|
|
|
|
|
|
|
|