Class: Buildr::Repositories
- Inherits:
-
Object
- Object
- Buildr::Repositories
- Includes:
- Singleton
- Defined in:
- lib/buildr/override/packaging/artifact.rb
Overview
Holds the path to the local repository, URLs for remote repositories, and settings for release server.
You can access this object from the #repositories method. For example:
puts repositories.local
repositories.remote << 'http://example.com/repo'
repositories.release_to = 'sftp://example.com/var/www/public/repo'
Instance Method Summary collapse
-
#remote=(urls) ⇒ Object
:call-seq: remote = Array remote = url remote = nil.
Instance Method Details
#remote=(urls) ⇒ Object
:call-seq:
remote = Array
remote = url
remote = nil
With a String argument, clears the array and set it to that single URL.
With an Array argument, clears the array and set it to these specific URLs.
With nil, clears the array.
166 167 168 169 170 171 172 173 |
# File 'lib/buildr/override/packaging/artifact.rb', line 166 def remote=(urls) case urls when nil then @remote = nil when RepositoryArray then @remote = urls when Array then @remote = RepositoryArray.new(urls.dup) else @remote = RepositoryArray.new([urls]) end end |