Import some signatures in incorrect format from Codeberg
This commit is contained in:
parent
b970932437
commit
ccaa517bfa
8 changed files with 28 additions and 0 deletions
2
_data/signed/Ricardo63.yaml
Normal file
2
_data/signed/Ricardo63.yaml
Normal file
|
@ -0,0 +1,2 @@
|
|||
name: Ricardo Morte Ferrer
|
||||
link: mailto:ricardo63@autistici.org
|
2
_data/signed/StariyLis.yaml
Normal file
2
_data/signed/StariyLis.yaml
Normal file
|
@ -0,0 +1,2 @@
|
|||
name: Aleksey Kuchkin
|
||||
link: mailto:stariylis@internet.ru
|
2
_data/signed/firgonstelsyou.yaml
Normal file
2
_data/signed/firgonstelsyou.yaml
Normal file
|
@ -0,0 +1,2 @@
|
|||
name: Nilolay Kirillov
|
||||
link: https://codeberg.org/firgonstelsyou
|
2
_data/signed/petr.tv.yaml
Normal file
2
_data/signed/petr.tv.yaml
Normal file
|
@ -0,0 +1,2 @@
|
|||
name: Petr Tonkoshurov
|
||||
link: mailto:petr@petr.tv
|
2
_data/signed/rtmpdavid.yaml
Normal file
2
_data/signed/rtmpdavid.yaml
Normal file
|
@ -0,0 +1,2 @@
|
|||
name: David Selivanov
|
||||
link: mailto:rtmpdavid@gmail.com
|
2
_data/signed/semerouk.yaml
Normal file
2
_data/signed/semerouk.yaml
Normal file
|
@ -0,0 +1,2 @@
|
|||
name: Mohammad Sameer
|
||||
link: https://www.mazayait.com
|
2
_data/signed/yudhasatya.yaml
Normal file
2
_data/signed/yudhasatya.yaml
Normal file
|
@ -0,0 +1,2 @@
|
|||
name: Yudha Satya
|
||||
link: https://codeberg.org/yudhasatya
|
|
@ -12,10 +12,24 @@ while True:
|
|||
content = comment["body"]
|
||||
|
||||
content_lines = [line.strip() for line in content.replace("`", "").strip().split("\n") if line.strip()]
|
||||
imported = False
|
||||
for i in range(len(content_lines) - 1):
|
||||
if content_lines[i].lower().startswith("name:") and content_lines[i + 1].lower().startswith("link:"):
|
||||
if not os.path.isfile(f"_data/signed/{author}.yaml"):
|
||||
with open(f"_data/signed/{author}.yaml", "w") as f:
|
||||
f.write("name:" + content_lines[i][5:] + "\nlink:" + content_lines[i + 1][5:] + "\n")
|
||||
imported = True
|
||||
if not imported and len(content_lines) == 2:
|
||||
name, link = content_lines
|
||||
if name.lower().startswith("name:"):
|
||||
name = name[5:]
|
||||
name = name.strip()
|
||||
if link.lower().startswith("link:"):
|
||||
link = link[5:]
|
||||
link = link.strip()
|
||||
if "/" in link or "@" in link:
|
||||
if not os.path.isfile(f"_data/signed/{author}.yaml"):
|
||||
with open(f"_data/signed/{author}.yaml", "w") as f:
|
||||
f.write(f"name: {name}\nlink: {link}\n")
|
||||
|
||||
page += 1
|
||||
|
|
Loading…
Reference in a new issue