From d38ce546b220abcadaefbebd3e8fac81c918ebbc Mon Sep 17 00:00:00 2001 From: prabhatdev Date: Fri, 31 Jul 2020 09:57:37 +0530 Subject: [PATCH] updated docker file --- .gitignore | 2 +- Dockerfile | 12 ++++++++++++ main.py | 4 ++-- 3 files changed, 15 insertions(+), 3 deletions(-) create mode 100644 Dockerfile diff --git a/.gitignore b/.gitignore index 89af850..f64f22c 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,4 @@ *.png node_modules/ __pycache__/ -Dockerfile + diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..2e72594 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,12 @@ +FROM nikolaik/python-nodejs:latest + +# Install dependencies. +ADD requirements.txt /requirements.txt +ADD main.py /main.py +ADD loc.py /loc.py +ADD make_bar_graph.py /make_bar_graph.py +ADD colors.json /colors.json +RUN pip install -r requirements.txt +RUN npm install vega-lite vega-cli canvas + +ENTRYPOINT ["python", "/main.py"] \ No newline at end of file diff --git a/main.py b/main.py index dc6f26e..be827f9 100644 --- a/main.py +++ b/main.py @@ -93,7 +93,7 @@ def run_v3_api(query): repositoryListQuery = Template(""" { user(login: "$username") { - repositories(orderBy: {field: CREATED_AT, direction: ASC}, last: 5, affiliations: [OWNER, COLLABORATOR, ORGANIZATION_MEMBER], isFork: false) { + repositories(orderBy: {field: CREATED_AT, direction: ASC}, last: 100, affiliations: [OWNER, COLLABORATOR, ORGANIZATION_MEMBER], isFork: false) { totalCount edges { node { @@ -374,7 +374,7 @@ def get_stats(): if show_waka_stats.lower() in ['true', '1', 't', 'y', 'yes']: stats = stats + get_waka_time_stats() - + if showLanguagePerRepo.lower() in ['true', '1', 't', 'y', 'yes']: stats = stats + generate_language_per_repo(repositoryList) + '\n\n'