Logo
Explore Help
Sign In
admin/brew
1
0
Fork 0
You've already forked brew
Code Issues Packages Projects Releases 6 Wiki Activity
brew/Library/Homebrew/cmd/tap-pin.rb

12 lines
182 B
Ruby
Raw Normal View History

implement pinning of taps
2015-08-09 22:42:46 +08:00
require "cmd/tap"
module Homebrew
def tap_pin
tap-pin: simplify logic
2015-08-25 17:13:37 +02:00
ARGV.named.each do |name|
cache taps 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>
2015-09-27 16:52:14 +08:00
tap = Tap.fetch(*tap_args(name))
implement pinning of taps
2015-08-09 22:42:46 +08:00
tap.pin
ohai "Pinned #{tap.name}"
end
end
end
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.23.8 Page: 474ms Template: 23ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API