Extracted function calls.

This commit is contained in:
Jochen Kupperschmidt
2016-06-05 23:41:47 +02:00
parent ca1dc8f00e
commit f6727b2555

View File

@ -326,11 +326,11 @@ def main():
if not ghe: if not ghe:
git_base = GITHUB_BASE_URL git_base = GITHUB_BASE_URL
cal = get_calendar(username, git_base)
else: else:
cal = get_calendar(username, ghe)
git_base = ghe git_base = ghe
cal = get_calendar(username, git_base)
m = calculate_multiplier(find_max_commits(cal)) m = calculate_multiplier(find_max_commits(cal))
print('Enter name of the repo to be used by gitfiti:') print('Enter name of the repo to be used by gitfiti:')
@ -380,12 +380,11 @@ def main():
if not ghe: if not ghe:
git_url = 'git@github.com' git_url = 'git@github.com'
output = fake_it(image, start_date, username, repo, git_url, offset,
fake_it_multiplier)
else: else:
git_url = request_user_input('Enter Git URL like git@site.github.com: ') git_url = request_user_input('Enter Git URL like git@site.github.com: ')
output = fake_it(image, start_date, username, repo, git_url, offset,
fake_it_multiplier) output = fake_it(image, start_date, username, repo, git_url, offset,
fake_it_multiplier)
save(output, 'gitfiti.sh') save(output, 'gitfiti.sh')
print('gitfiti.sh saved.') print('gitfiti.sh saved.')