summaryrefslogtreecommitdiff
path: root/lib/bundler/plugin
diff options
context:
space:
mode:
authorfotanus <fotanus@gmail.com>2017-05-24 16:31:30 -0300
committerfotanus <fotanus@gmail.com>2017-05-30 14:27:29 -0300
commita08d08eb9854435ba6d5ef513d95e295ab19e8a6 (patch)
tree97911883bb2772c270f0057d3a287188e0a541e7 /lib/bundler/plugin
parentbf26b5515926c51008f2fe9e9d0054260d482e74 (diff)
downloadbundler-a08d08eb9854435ba6d5ef513d95e295ab19e8a6.tar.gz
implement command `bundle plugin list`
Diffstat (limited to 'lib/bundler/plugin')
-rw-r--r--lib/bundler/plugin/index.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/bundler/plugin/index.rb b/lib/bundler/plugin/index.rb
index 8dde072f16..b9328d3177 100644
--- a/lib/bundler/plugin/index.rb
+++ b/lib/bundler/plugin/index.rb
@@ -95,6 +95,14 @@ module Bundler
@plugin_paths[name]
end
+ def installed_plugins
+ @plugin_paths.keys
+ end
+
+ def plugin_commands(plugin)
+ @commands.find_all {|_, n| n == plugins }.map(&:first)
+ end
+
def source?(source)
@sources.key? source
end