blob: b0fb6735ad9d7f63a3deaf14350ea4444df144ae (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# frozen_string_literal: true
module Bundler
# Dsl to parse the Gemfile looking for plugins to install
class Plugin::Dsl < Bundler::Dsl
alias_method :_gem, :gem # To use for plugin installation as gem
# So that we don't have to override all there methods to dummy ones
# explicitly.
# They will be handled by missing_methods
[:gemspec, :gem, :path, :install_if, :platforms, :env].each {|m| undef_method m }
def initialize
@sources = Plugin::SourceList.new
super
end
def plugin(name, *args)
_gem(name, *args)
end
def method_missing(name, *args)
# Dummy evaluation
end
end
end
|