Add alpha and beta versions
This commit is contained in:
20
alpha/gitea_simple_app/parser.py
Normal file
20
alpha/gitea_simple_app/parser.py
Normal file
@@ -0,0 +1,20 @@
|
||||
def parse_repo_info(data):
|
||||
return (
|
||||
f"Название: {data.get('name', '—')}\n"
|
||||
f"Описание: {data.get('description', '—')}\n"
|
||||
f"Автор: {data.get('owner', {}).get('login', '—')}\n"
|
||||
f"Создан: {data.get('created_at', '—')}\n"
|
||||
f"Изменён: {data.get('updated_at', '—')}\n"
|
||||
)
|
||||
|
||||
|
||||
def parse_authors(commits):
|
||||
authors = set()
|
||||
|
||||
for commit in commits:
|
||||
try:
|
||||
authors.add(commit["commit"]["author"]["name"])
|
||||
except:
|
||||
continue
|
||||
|
||||
return authors
|
||||
Reference in New Issue
Block a user