Class: Giblish::GitSummaryIndexBuilder

Inherits:
Object
  • Object
show all
Defined in:
lib/giblish/buildindex.rb

Overview

Builds an index page with a summary of what branches have been generated

Instance Method Summary collapse

Constructor Details

#initialize(repo, branches, tags) ⇒ GitSummaryIndexBuilder

Returns a new instance of GitSummaryIndexBuilder.



374
375
376
377
378
379
# File 'lib/giblish/buildindex.rb', line 374

def initialize(repo, branches, tags)
  @branches = branches
  @tags = tags
  @git_repo = repo
  @repo_url = repo.remote.url
end

Instance Method Details

#sourceObject



381
382
383
384
385
386
387
388
# File 'lib/giblish/buildindex.rb', line 381

def source
  <<~ADOC_SRC
    #{generate_header}
    #{generate_branch_info}
    #{generate_tag_info}
    #{generate_footer}
  ADOC_SRC
end