Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: korean, format string #136

Merged
merged 3 commits into from
Dec 5, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 8 additions & 11 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ def generate_commit_list(tz):
for day in dayOfWeek:
if day['percent'] > max_element['percent']:
max_element = day
days_title = translate['I am Most Productive on'] + ' ' + max_element['name']
days_title = translate['I am Most Productive on'] % max_element['name']
string = string + '📅 **' + days_title + '** \n\n' + '```text\n' + make_commit_list(dayOfWeek) + '\n\n```\n'

return string
Expand Down Expand Up @@ -378,7 +378,7 @@ def generate_language_per_repo(result):
"percent": percent
})

title = translate['I Mostly Code in'] + ' ' + most_language_repo
title = translate['I Mostly Code in'] % most_language_repo
return '**' + title + '** \n\n' + '```text\n' + make_list(data) + '\n\n```\n'


Expand Down Expand Up @@ -411,10 +411,9 @@ def get_short_info(github):
data = request.json()
total = data['years'][0]['total']
year = data['years'][0]['year']
string += '> 🏆 ' + humanize.intcomma(total) + " " + translate[
'Contributions in the year'] + " " + year + '\n > \n'
string += '> 🏆 ' + translate['Contributions in the year'] % (humanize.intcomma(total), year) + '\n > \n'

string += '> 📦 ' + disk_usage + " " + translate["Used in GitHub's Storage"] + ' \n > \n'
string += '> 📦 ' + translate["Used in GitHub's Storage"] % disk_usage + ' \n > \n'
is_hireable = user_info.hireable
public_repo = user_info.public_repos
private_repo = user_info.owned_private_repos
Expand All @@ -425,12 +424,10 @@ def get_short_info(github):
else:
string += "> 🚫 " + translate["Not Opted to Hire"] + "\n > \n"

string += '> 📜 ' + str(public_repo) + " "
string += translate['public repositories'] + '\n > \n' if public_repo > 1 else translate[
'public repository'] + ' \n > \n'
string += '> 🔑 ' + str(private_repo) + " "
string += translate['private repositories'] + ' \n\n' if private_repo > 1 else translate[
'private repository'] + ' \n > \n'
string += '> 📜 ' + translate['public repositories'] % public_repo + " " + '\n > \n' if public_repo > 1 else translate[
'public repository'] % public_repo + ' \n > \n'
string += '> 🔑 ' + translate['private repositories'] % private_repo + " " +' \n\n' if private_repo > 1 else translate[
'private repository'] % public_repo + ' \n > \n'

return string

Expand Down
165 changes: 101 additions & 64 deletions translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,23 +16,23 @@
"operating system": "Système d'exploitation",
"Projects": "Projets",
"Timezone": "Fuseau horaire",
"Contributions in the year": "Contributions en",
"Used in GitHub's Storage": "Utilisés avec le stockage de GitHub",
"Contributions in the year": "%s Contributions en %s",
"Used in GitHub's Storage": "%s Utilisés avec le stockage de GitHub",
"Opted to Hire": "A choisi d'embaucher",
"Not Opted to Hire": "N'a pas choisi d'embaucher",
"Profile Views": "Vues du profil",
"From Hello World I have written": "Depuis Hello World, j'ai écrit",
"I am Most Productive on": "Je suis le plus productif sur",
"I am Most Productive on": "Je suis le plus productif sur %s",
"This Week I Spend My Time On": "Cette semaine, je passe mon temps sur",
"I Mostly Code in": "Je code principalement en",
"I Mostly Code in": "Je code principalement en %s",
"Timeline": "Chronologie",
"No Activity Tracked This Week": "Aucune activité enregistrée cette semaine",
"My GitHub Data": "Mes données GitHub",
"Lines of code": "Lignes de code",
"public repository": "dépot publique",
"public repositories": "dépots publiques",
"private repository": "dépot privé",
"private repositories": "dépots privés",
"public repository": "%d dépot publique",
"public repositories": "%d dépots publiques",
"private repository": "%d dépot privé",
"private repositories": "%d dépots privés",
"I am an Early": "Je suis un 🐤 du matin",
"I am a Night": "Je suis un 🦉 de nuit"
},
Expand All @@ -53,23 +53,23 @@
"operating system": "Operating System",
"Projects": "Projects",
"Timezone": "Time Zone",
"Contributions in the year": "Contributions in the Year",
"Used in GitHub's Storage": "Used in Github's Storage",
"Contributions in the year": "%s Contributions in the Year %s",
"Used in GitHub's Storage": "%s Used in Github's Storage",
"Opted to Hire": "Opted to Hire",
"Not Opted to Hire": "Not Opted to Hire",
"Profile Views": "Profile Views",
"From Hello World I have written": "From Hello World I've Written",
"I am Most Productive on": "I'm Most Productive on",
"I am Most Productive on": "I'm Most Productive on %s",
"This Week I Spend My Time On": "This Week I Spent My Time On",
"I Mostly Code in": "I Mostly Code in",
"I Mostly Code in": "I Mostly Code in %s",
"Timeline": "Timeline",
"No Activity Tracked This Week": "No Activity Tracked This Week",
"My GitHub Data": "My Github Data",
"Lines of code": "lines of code",
"public repository": "Public Repository",
"public repositories": "Public Repositories",
"private repository": "Private Repository",
"private repositories": "Private Repositories",
"public repository": "%d Public Repository",
"public repositories": "%d Public Repositories",
"private repository": "%d Private Repository",
"private repositories": "%d Private Repositories",
"I am an Early": "I'm an Early 🐤",
"I am a Night": "I'm a Night 🦉"
},
Expand All @@ -90,23 +90,23 @@
"operating system": "Sistema operativo",
"Projects": "Progetti",
"Timezone": "Fuso orario",
"Contributions in the year": "Contributi nell'ultimo anno",
"Used in GitHub's Storage": "Spazio di archiviazione di Github utilizzato",
"Contributions in the year": "%s Contributi nell'ultimo anno %s",
"Used in GitHub's Storage": "%s Spazio di archiviazione di Github utilizzato",
"Opted to Hire": "Pronto per essere assunto",
"Not Opted to Hire": "Non disponibile per assunzioni/colloqui",
"Profile Views": "Visite al profilo",
"From Hello World I have written": "Dal mio primo Hello World ho scritto ",
"I am Most Productive on": "Sono piu' produttivo di",
"I am Most Productive on": "Sono piu' produttivo di %s",
"This Week I Spend My Time On": "Questa settimana ho speso il mio tempo su",
"I Mostly Code in": "Solitamente programmo in",
"I Mostly Code in": "Solitamente programmo in %s",
"Timeline": "Linea temporale",
"No Activity Tracked This Week": "Nessuna attività tracciata questa settimana",
"My GitHub Data": "I miei dati GitHub",
"Lines of code": "Linee di codice",
"public repository": "Repository pubblica",
"public repositories": "Repositories pubbliche",
"private repository": "Repository privata",
"private repositories": "Repositories private",
"public repository": "%d Repository pubblica",
"public repositories": "%d Repositories pubbliche",
"private repository": "%d Repository privata",
"private repositories": "%d Repositories private",
"I am an Early": "Sono un mattiniero 🐤",
"I am a Night": "Sono un notturno 🦉"
},
Expand All @@ -127,23 +127,23 @@
"operating system": "操作系统",
"Projects": "项目",
"Timezone": "时区",
"Contributions in the year": "今年的贡献",
"Used in GitHub's Storage": "占用了 GitHub 内存",
"Contributions in the year": "%s 今年的贡献 %s",
"Used in GitHub's Storage": "%s 占用了 GitHub 内存",
"Opted to Hire": "开放招聘",
"Not Opted to Hire": "不开放招聘",
"Profile Views": "个人封面观看次数",
"From Hello World I have written": "从「你好世界」我已经写了",
"I am Most Productive on": "我最有效率是",
"I am Most Productive on": "我最有效率是 %s",
"This Week I Spend My Time On": "这周我的时间花在了",
"I Mostly Code in": "我主要编写",
"I Mostly Code in": "我主要编写 %s",
"Timeline": "时间线",
"No Activity Tracked This Week": "本周没有记录任何活动",
"My GitHub Data": "我的 GitHub 数据",
"Lines of code": "行代码",
"public repository": "公共仓库",
"public repositories": "公共仓库",
"private repository": "私人仓库",
"private repositories": "私人仓库",
"public repository": "%d 公共仓库",
"public repositories": "%d 公共仓库",
"private repository": "%d 私人仓库",
"private repositories": "%d 私人仓库",
"I am an Early": "我是早起的 🐤",
"I am a Night": "我是晚睡的 🦉"
},
Expand All @@ -164,23 +164,23 @@
"operating system": "نظام التشغيل",
"Projects": "مشاريع",
"Timezone": "التوقيت زمني",
"Contributions in the year": "مساهماتي خلال السنة",
"Used in GitHub's Storage": "Github المساحة المستخدمة في",
"Contributions in the year": "%s مساهماتي خلال السنة %s",
"Used in GitHub's Storage": "%s Github المساحة المستخدمة في",
"Opted to Hire": "متاح للتوظيف",
"Not Opted to Hire": "غير متاح للتوظيف",
"Profile Views": "Profile Views",
"From Hello World I have written": "From Hello World I have written",
"I am Most Productive on": "انا اكثر انتاجية في يوم",
"I am Most Productive on": "انا اكثر انتاجية في يوم %s",
"This Week I Spend My Time On": "هذا الاسبوع قضيت وقتي في",
"I Mostly Code in": "اغلب وقتي استخدم",
"I Mostly Code in": "اغلب وقتي استخدم %s",
"Timeline": "الجدول الزمني",
"No Activity Tracked This Week": "لم يتم تتبع أي نشاط هذا الأسبوع",
"My GitHub Data": "Github بياناتي في",
"Lines of code": "أسطر من التعليمات البرمجية",
"public repository": "المستودع العام",
"public repositories": "المستودعات العامة",
"private repository": "المستودع الخاص",
"private repositories": "المستودعات الخاصة",
"public repository": "%d المستودع العام",
"public repositories": "%d المستودعات العامة",
"private repository": "%d المستودع الخاص",
"private repositories": "%d المستودعات الخاصة",
"I am an Early": "أنا كالعصفور 🐤 في الصباح",
"I am a Night": "أنا كالبومة 🦉 في الليل"
},
Expand All @@ -201,23 +201,23 @@
"operating system": "Sistema operacional",
"Projects": "Projetos",
"Timezone": "Fuso horário",
"Contributions in the year": "Contribuições no ano",
"Used in GitHub's Storage": "Usado no armazenamento do Github",
"Contributions in the year": "%s Contribuições no ano %s",
"Used in GitHub's Storage": "%s Usado no armazenamento do Github",
"Opted to Hire": "Optou por contratar",
"Not Opted to Hire": "Não optou por contratar",
"Profile Views": "Visualizacões do perfil",
"From Hello World I have written": "Desde o Hello World eu escrevi",
"I am Most Productive on": "Sou mais produtivo em",
"I am Most Productive on": "Sou mais produtivo em %s",
"This Week I Spend My Time On": "Esta semana eu gastei meu tempo em",
"I Mostly Code in": "Eu principalmente codifico em",
"I Mostly Code in": "Eu principalmente codifico em %s",
"Timeline": "Linha do tempo",
"No Activity Tracked This Week": "Nenhuma atividade rastreada esta semana",
"My GitHub Data": "Meus dados no Github",
"Lines of code": "linhas de código",
"public repository": "Repositório Público",
"public repositories": "Repositórios Públicos",
"private repository": "Repositório Privado",
"private repositories": "Repositórios Privados",
"public repository": "%d Repositório Público",
"public repositories": "%d Repositórios Públicos",
"private repository": "%d Repositório Privado",
"private repositories": "%d Repositórios Privados",
"I am an Early": "Eu sou diurno 🐤",
"I am a Night": "Eu sou noturno 🦉"
},
Expand All @@ -238,23 +238,23 @@
"operating system": "System operacyjny",
"Projects": "Projekty",
"Timezone": "Strefa czasowa",
"Contributions in the year": "kontrybucji w roku",
"Used in GitHub's Storage": "zajętego miejsca na Github",
"Contributions in the year": "%s kontrybucji w roku %s",
"Used in GitHub's Storage": "%s zajętego miejsca na Github",
"Opted to Hire": "szukam zarudnienia",
"Not Opted to Hire": "nie szukam zatrudnienia",
"Profile Views": "wyświetlenia profilu",
"From Hello World I have written": "Od Hello World napisałem",
"I am Most Productive on": "Dzień, w którym jestem najbardziej produktywny",
"I am Most Productive on": "Dzień, w którym jestem najbardziej produktywny %s",
"This Week I Spend My Time On": "Czas poświęcony na projekty w tym tygodniu",
"I Mostly Code in": "Najczęściej piszę w ",
"I Mostly Code in": "Najczęściej piszę w %s",
"Timeline": "Linia czasu",
"No Activity Tracked This Week": "Brak aktywności w tym tygodniu",
"My GitHub Data": "Mój GitHub",
"Lines of code": "linii kodu",
"public repository": "publiczne repozytoria",
"public repositories": "publiczne repozytorium",
"private repository": "prywatne repozytorium",
"private repositories": "prywatne repozytoria",
"public repository": "%d publiczne repozytoria",
"public repositories": "%d publiczne repozytorium",
"private repository": "%d prywatne repozytorium",
"private repositories": "%d prywatne repozytoria",
"I am an Early": "Jestem rannym 🐤",
"I am a Night": "Jestem nocną 🦉"
},
Expand All @@ -275,24 +275,61 @@
"operating system": "Systema Operativo",
"Projects": "Proyectos",
"Timezone": "Zona Horaria",
"Contributions in the year": "Contribuciones durante el año",
"Used in GitHub's Storage": "Almacenamiento de Github utilizado",
"Contributions in the year": "%s Contribuciones durante el año %s",
"Used in GitHub's Storage": "%s Almacenamiento de Github utilizado",
"Opted to Hire": "Abierto a contratación",
"Not Opted to Hire": "No abierto para contratación",
"Profile Views": "Visitas al perfil",
"From Hello World I have written": "Desde Hola Mundo he escrito",
"I am Most Productive on": "Soy más productivo los",
"I am Most Productive on": "Soy más productivo los %s",
"This Week I Spend My Time On": "Esta semana me dediqué a",
"I Mostly Code in": "Codifico principalmente en",
"I Mostly Code in": "Codifico principalmente en %s",
"Timeline": "Cronología",
"No Activity Tracked This Week": "Sin actividad registrada esta semana",
"My GitHub Data": "Mis datos de Github",
"Lines of code": "Lineas de código",
"public repository": "Repositorio Público",
"public repositories": "Repositorios Públicos",
"private repository": "Repositorio Privado",
"private repositories": "Repositorios Privados",
"public repository": "%d Repositorio Público",
"public repositories": "%d Repositorios Públicos",
"private repository": "%d Repositorio Privado",
"private repositories": "%d Repositorios Privados",
"I am an Early": "Soy diurno 🐤",
"I am a Night": "Soy nocturno 🦉"
},
"ko": {
"Monday": "월요일",
"Tuesday": "화요일",
"Wednesday": "수요일",
"Thursday": "목요일",
"Friday": "금요일",
"Saturday": "토요일",
"Sunday": "일요일",
"Morning": "아침",
"Daytime": "낮 ",
"Evening": "저녁",
"Night": "밤 ",
"Languages": "프로그래밍 언어들",
"Editors": "에디터들",
"operating system": "운영 체제들",
"Projects": "프로젝트들",
"Timezone": "Timezone",
"Contributions in the year": "%s 만큼의 Contributions을 %s년에 했어요",
"Used in GitHub's Storage": "Github의 %s만큼의 저장소를 사용하고 있어요.",
"Opted to Hire": "구직중이에요.",
"Not Opted to Hire": "구직중이지 않아요.",
"Profile Views": "Profile Views",
"From Hello World I have written": "저는 여태까지 ",
"I am Most Productive on": "제가 가장 생산적인 날은 %s이에요.",
"This Week I Spend My Time On": "저는 이번주를 이렇게 시간을 보냈어요.",
"I Mostly Code in": "저는 주로 %s 언어를 사용해요.",
"Timeline": "타임라인",
"No Activity Tracked This Week": "이번 주에 활동은 없어요.",
"My GitHub Data": "저의 Github 정보에요.",
"Lines of code": "줄의 코드를 작성했어요.",
"public repository": "%d개의 Public Repository를 만들었어요.",
"public repositories": "%d개의 Public Repository를 만들었어요.",
"private repository": "%d개의 Private Repository를 만들었어요.",
"private repositories": "%d개의 Private Repository를 만들었어요.",
"I am an Early": "저는 아침형 인간이에요. 🐤",
"I am a Night": "저는 저녁형 인간이에요. 🦉"
}
}