instance method
Gem::SourceList#append
append(obj)
lib/rubygems/source_list.rb
View on GitHub ↗
# File tmp/rubies/ruby-4.0.0/lib/rubygems/source_list.rb, line 85
def append(obj)
src = case obj
when Gem::Source
obj
else
Gem::Source.new(obj)
end
@sources.delete(src) if @sources.include?(src)
@sources << src
src
end
Appends obj to the end of the source list, moving it if already present. obj may be a Gem::Source, Gem::URI or URI String. Moves obj to the end of the list if already present.