Skip to content
This repository has been archived by the owner on May 11, 2022. It is now read-only.

Commit

Permalink
Merge pull request #12 from TheRenegadeCoder/language-totals
Browse files Browse the repository at this point in the history
Added Language Totaling Support
  • Loading branch information
jrg94 authored Aug 12, 2018
2 parents d959cdf + 045e06c commit 1d0d613
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions generate_wiki/generate_wiki.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,11 +152,14 @@ def build_alphabet_page(self, letter):
page.add_section_break()
page.add_table_header("Language", "Article(s)", "Issue(s)", "# of Snippets")
languages_by_letter = self.repo.get_languages_by_letter(letter)
total_snippets = 0
for language in languages_by_letter:
total_snippets += language.total_snippets
language_link = self.build_repo_link(language.name.capitalize(), letter, language.name)
tag_link = self.build_tag_link(language.name)
issues_link = self.build_issue_link(language.name)
page.add_table_row(language_link, tag_link, issues_link, str(language.total_snippets))
page.add_table_row("**Totals**", "", "", str(total_snippets))
page.add_section_break()
return page

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

setuptools.setup(
name="generate_wiki",
version="1.0.1",
version="1.0.2",
author="The Renegade Coder",
author_email="[email protected]",
description="A wiki generation package for the Sample Programs repo",
Expand Down

0 comments on commit 1d0d613

Please sign in to comment.