Sha256: bd9de0ab0bcddbf75f3425b66cc3b85816a18f5ace835806cd504a8bff7efbb0

Contents?: true

Size: 519 Bytes

Versions: 12

Compression:

Stored size: 519 Bytes

Contents

module AsciiBinder
  class SiteInfo
    attr_reader :id, :name, :url, :distros, :branches

    def initialize(distro)
      @id       = distro.site.id
      @name     = distro.site.name
      @url      = distro.site.url
      @distros  = {}
      @branches = ['master']
      add_distro(distro)
    end

    def add_distro(distro)
      @distros[distro.id] = distro.branches
      distro.branches.each do |branch|
        next if @branches.include?(branch.id)
        @branches << branch.id
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
ascii_binder-0.2.2 lib/ascii_binder/site_info.rb
ascii_binder-0.2.1 lib/ascii_binder/site_info.rb
ascii_binder-0.2.0 lib/ascii_binder/site_info.rb
ascii_binder-0.1.15.3 lib/ascii_binder/site_info.rb
ascii_binder-0.1.15.2 lib/ascii_binder/site_info.rb
ascii_binder-0.1.15.1 lib/ascii_binder/site_info.rb
ascii_binder-0.1.15 lib/ascii_binder/site_info.rb
ascii_binder-0.1.14 lib/ascii_binder/site_info.rb
ascii_binder-0.1.13 lib/ascii_binder/site_info.rb
ascii_binder-0.1.11 lib/ascii_binder/site_info.rb
ascii_binder-0.1.10.1 lib/ascii_binder/site_info.rb
ascii_binder-0.1.10 lib/ascii_binder/site_info.rb