Method: Bundler::Dsl#git_source
- Defined in:
- lib/bundler/dsl.rb
permalink #git_source(name, &block) ⇒ Object
[View source]
128 129 130 131 132 133 134 135 136 137 138 139 |
# File 'lib/bundler/dsl.rb', line 128 def git_source(name, &block) unless block_given? raise InvalidOption, "You need to pass a block to #git_source" end if valid_keys.include?(name.to_s) raise InvalidOption, "You cannot use #{name} as a git source. It " \ "is a reserved key. Reserved keys are: #{valid_keys.join(", ")}" end @git_sources[name.to_s] = block end |