mirror of
https://gitlab.com/chicken-riders/RcGcDw.git
synced 2025-02-23 00:24:09 +00:00
added #105 + updated German translation
This commit is contained in:
parent
eb0fd43e2c
commit
5b7a940a6d
BIN
locale/de/LC_MESSAGES/discussions.mo
Normal file
BIN
locale/de/LC_MESSAGES/discussions.mo
Normal file
Binary file not shown.
47
locale/de/LC_MESSAGES/discussions.po
Normal file
47
locale/de/LC_MESSAGES/discussions.po
Normal file
|
@ -0,0 +1,47 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
||||
# This file is distributed under the same license as the PACKAGE package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2020-04-06 18:55+0200\n"
|
||||
"PO-Revision-Date: 2020-04-07 11:53+0200\n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 2.3\n"
|
||||
"Last-Translator: \n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"Language: de\n"
|
||||
|
||||
#: discussions.py:53
|
||||
#, python-brace-format
|
||||
msgid "Replied to \"{title}\""
|
||||
msgstr "Antwortete auf „{title}“"
|
||||
|
||||
#: discussions.py:56
|
||||
#, python-brace-format
|
||||
msgid "Created \"{title}\""
|
||||
msgstr "Erstellte „{title}“"
|
||||
|
||||
#: discussions.py:73
|
||||
#, python-brace-format
|
||||
msgid ""
|
||||
"[{author}](<{url}f/u/{creatorId}>) created [{title}](<{url}f/p/{threadId}>) "
|
||||
"in {forumName}"
|
||||
msgstr ""
|
||||
"[{author}](<{url}f/u/{creatorId}>) erstellte [{title}](<{url}f/p/{threadId}"
|
||||
">) in {forumName}"
|
||||
|
||||
#: discussions.py:76
|
||||
#, python-brace-format
|
||||
msgid ""
|
||||
"[{author}](<{url}f/u/{creatorId}>) created a [reply](<{url}f/p/{threadId}/r/"
|
||||
"{postId}>) to [{title}](<{url}f/p/{threadId}>) in {forumName}"
|
||||
msgstr ""
|
||||
"[{author}](<{url}f/u/{creatorId}>) erstellte eine [Antwork](<{url}f/p/"
|
||||
"{threadId}/r/{postId}>) zu [{title}](<{url}f/p/{threadId}>) in {forumName}"
|
36
rcgcdw.py
36
rcgcdw.py
|
@ -1388,26 +1388,32 @@ except requests.exceptions.ConnectionError:
|
|||
logger.critical("A connection can't be established with the wiki. Exiting...")
|
||||
sys.exit(1)
|
||||
time.sleep(3.0) # this timeout is to prevent timeouts. It seems Fandom does not like our ~2-3 request in under a second
|
||||
logger.info("Script started! Fetching newest changes...")
|
||||
recent_changes.fetch(amount=settings["limitrefetch"] if settings["limitrefetch"] != -1 else settings["limit"])
|
||||
if settings["rc_enabled"]:
|
||||
logger.info("Script started! Fetching newest changes...")
|
||||
recent_changes.fetch(amount=settings["limitrefetch"] if settings["limitrefetch"] != -1 else settings["limit"])
|
||||
schedule.every(settings["cooldown"]).seconds.do(recent_changes.fetch)
|
||||
if settings["overview"]:
|
||||
try:
|
||||
overview_time = time.strptime(settings["overview_time"], '%H:%M')
|
||||
schedule.every().day.at("{}:{}".format(str(overview_time.tm_hour).zfill(2),
|
||||
str(overview_time.tm_min).zfill(2))).do(day_overview)
|
||||
del overview_time
|
||||
except schedule.ScheduleValueError:
|
||||
logger.error("Invalid time format! Currently: {}:{}".format(
|
||||
time.strptime(settings["overview_time"], '%H:%M').tm_hour,
|
||||
time.strptime(settings["overview_time"], '%H:%M').tm_min))
|
||||
except ValueError:
|
||||
logger.error("Invalid time format! Currentely: {}. Note: It needs to be in HH:MM format.".format(
|
||||
settings["overview_time"]))
|
||||
schedule.every().day.at("00:00").do(recent_changes.clear_cache)
|
||||
else:
|
||||
logger.info("Script started! RC is disabled however, this means no recent changes will be sent :c")
|
||||
|
||||
schedule.every(settings["cooldown"]).seconds.do(recent_changes.fetch)
|
||||
if 1 == 2: # additional translation strings in unreachable code
|
||||
# noinspection PyUnreachableCode
|
||||
print(_("director"), _("bot"), _("editor"), _("directors"), _("sysop"), _("bureaucrat"), _("reviewer"),
|
||||
_("autoreview"), _("autopatrol"), _("wiki_guardian"), ngettext("second", "seconds", 1), ngettext("minute", "minutes", 1), ngettext("hour", "hours", 1), ngettext("day", "days", 1), ngettext("week", "weeks", 1), ngettext("month", "months",1), ngettext("year", "years", 1), ngettext("millennium", "millennia", 1), ngettext("decade", "decades", 1), ngettext("century", "centuries", 1))
|
||||
# noinspection PyUnreachableCode
|
||||
|
||||
if settings["overview"]:
|
||||
try:
|
||||
overview_time = time.strptime(settings["overview_time"], '%H:%M')
|
||||
schedule.every().day.at("{}:{}".format(str(overview_time.tm_hour).zfill(2),
|
||||
str(overview_time.tm_min).zfill(2))).do(day_overview)
|
||||
del overview_time
|
||||
except schedule.ScheduleValueError:
|
||||
logger.error("Invalid time format! Currently: {}:{}".format(time.strptime(settings["overview_time"], '%H:%M').tm_hour, time.strptime(settings["overview_time"], '%H:%M').tm_min))
|
||||
except ValueError:
|
||||
logger.error("Invalid time format! Currentely: {}. Note: It needs to be in HH:MM format.".format(settings["overview_time"]))
|
||||
schedule.every().day.at("00:00").do(recent_changes.clear_cache)
|
||||
|
||||
if TESTING:
|
||||
logger.debug("DEBUGGING ")
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{
|
||||
"cooldown": 60,
|
||||
"wiki_url": "https://wreckit-woodhouse.fandom.com/",
|
||||
"rc_enabled": true,
|
||||
"lang": "en",
|
||||
"header": {
|
||||
"user-agent": "RcGcDw/{version}"
|
||||
|
|
Loading…
Reference in a new issue