From cbe6c08f444cb583c835830903c4adea57a6d20d Mon Sep 17 00:00:00 2001
From: boxydog
Date: Fri, 31 May 2024 08:48:32 -0500
Subject: [PATCH 01/52] Don't ignore ruff B007, RUF015, PLR1722
---
pyproject.toml | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git a/pyproject.toml b/pyproject.toml
index b7e39a4a..606a05ba 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -168,7 +168,6 @@ select = [
ignore = [
# suppression in order of # of violations in Dec 2023:
- "B007", # unused-loop-control-variable
"T201", # print
"PLW2901", # redefined-loop-name
"SLF001", # private-member-access
@@ -176,12 +175,18 @@ ignore = [
"PLR2004", # magic-value-comparison
"PLR0912", # too-many-branches
"PLR0913", # too-many-arguments
+ # RUF005: this is a different style of concatenating literals. It perhaps performs
+ # a bit better, but doesn't seem any more readable to me. So, ignore it.
"RUF005", # collection-literal-concatenation
+ # TODO: several classes have class variables. If that is correct, we should
+ # annotate them with ClassVar.
+ # See https://docs.astral.sh/ruff/rules/mutable-class-default/
"RUF012", # mutable-class-default
"PLR0915", # too-many-statements
+ # Note: we have a couple of "namespace packages" (i.e. missing __init__.py)
+ # Not sure if we should add __init__.py to them, or they really need to be
+ # namespace packages.
"INP001", # implicit-namespace-package
- "RUF015", # unnecessary-iterable-allocation-for-first-element
- "PLR1722", # sys-exit-alias
# ruff-format wants us to ignore ISC001. I don't love that, but okay.
# "warning: The following rules may cause conflicts when used with the formatter:
# `ISC001`. To avoid unexpected behavior, we recommend disabling these rules,
From 9b77a9027bea3596c9ced8ba4890c2928e978ce1 Mon Sep 17 00:00:00 2001
From: boxydog
Date: Fri, 31 May 2024 08:48:44 -0500
Subject: [PATCH 02/52] File fixes for ruff B007, RUF015, PLR1722
---
pelican/tests/test_importer.py | 72 ++++++++++++++++-----------------
pelican/tests/test_utils.py | 11 ++---
pelican/tools/pelican_import.py | 12 +++---
pelican/utils.py | 2 +-
pelican/writers.py | 2 +-
5 files changed, 48 insertions(+), 51 deletions(-)
diff --git a/pelican/tests/test_importer.py b/pelican/tests/test_importer.py
index 46d83432..b00970f4 100644
--- a/pelican/tests/test_importer.py
+++ b/pelican/tests/test_importer.py
@@ -108,15 +108,15 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
self.assertTrue(self.posts)
for (
title,
- content,
- fname,
- date,
- author,
- categ,
- tags,
- status,
- kind,
- format,
+ _content,
+ _fname,
+ _date,
+ _author,
+ _categ,
+ _tags,
+ _status,
+ _kind,
+ _format,
) in self.posts:
self.assertTrue(title.strip())
@@ -127,15 +127,15 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
pages_data = []
for (
title,
- content,
+ _content,
fname,
- date,
- author,
- categ,
- tags,
- status,
+ _date,
+ _author,
+ _categ,
+ _tags,
+ _status,
kind,
- format,
+ _format,
) in self.posts:
if kind == "page":
pages_data.append((title, fname))
@@ -147,7 +147,7 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
silent_f2p = mute(True)(fields2pelican)
test_post = filter(lambda p: p[0].startswith("Empty Page"), self.posts)
with temporary_folder() as temp:
- fname = list(silent_f2p(test_post, "markdown", temp, dirpage=True))[0]
+ fname = next(iter(silent_f2p(test_post, "markdown", temp, dirpage=True)))
self.assertTrue(fname.endswith("pages%sempty.md" % os.path.sep))
def test_dircat(self):
@@ -176,15 +176,15 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
pages_data = []
for (
title,
- content,
+ _content,
fname,
- date,
- author,
- categ,
- tags,
- status,
+ _date,
+ _author,
+ _categ,
+ _tags,
+ _status,
kind,
- format,
+ _format,
) in self.posts:
if kind in {"page", "article"}:
pass
@@ -197,15 +197,15 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
cust_data = []
for (
title,
- content,
- fname,
- date,
- author,
- categ,
- tags,
- status,
+ _content,
+ _fname,
+ _date,
+ _author,
+ _categ,
+ _tags,
+ _status,
kind,
- format,
+ _format,
) in self.custposts:
if kind in {"page", "article"}:
pass
@@ -346,7 +346,7 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
silent_f2p = mute(True)(fields2pelican)
test_post = filter(lambda p: p[0].startswith("Code in List"), self.posts)
with temporary_folder() as temp:
- md = [r(f) for f in silent_f2p(test_post, "markdown", temp)][0]
+ md = next(r(f) for f in silent_f2p(test_post, "markdown", temp))
self.assertTrue(re.search(r"\s+a = \[1, 2, 3\]", md))
self.assertTrue(re.search(r"\s+b = \[4, 5, 6\]", md))
@@ -362,7 +362,7 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
silent_f2p = mute(True)(fields2pelican)
test_post = filter(lambda p: p[0].startswith("Code in List"), self.posts)
with temporary_folder() as temp:
- md = [r(f) for f in silent_f2p(test_post, "markdown", temp)][0]
+ md = next(r(f) for f in silent_f2p(test_post, "markdown", temp))
sample_line = re.search(r"- This is a code sample", md).group(0)
code_line = re.search(r"\s+a = \[1, 2, 3\]", md).group(0)
self.assertTrue(sample_line.rindex("This") < code_line.rindex("a"))
@@ -375,7 +375,7 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
silent_f2p = mute(True)(fields2pelican)
test_post = filter(lambda p: p[0].startswith("Post with raw data"), self.posts)
with temporary_folder() as temp:
- md = [r(f) for f in silent_f2p(test_post, "markdown", temp)][0]
+ md = next(r(f) for f in silent_f2p(test_post, "markdown", temp))
escaped_quotes = re.search(r'\\[\'"“”‘’]', md)
self.assertFalse(escaped_quotes)
@@ -387,7 +387,7 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
silent_f2p = mute(True)(fields2pelican)
test_post = filter(lambda p: p[0].startswith("Caption on image"), self.posts)
with temporary_folder() as temp:
- md = [r(f) for f in silent_f2p(test_post, "markdown", temp)][0]
+ md = next(r(f) for f in silent_f2p(test_post, "markdown", temp))
caption = re.search(r"\[caption", md)
self.assertFalse(caption)
diff --git a/pelican/tests/test_utils.py b/pelican/tests/test_utils.py
index 6c25cf45..beda7140 100644
--- a/pelican/tests/test_utils.py
+++ b/pelican/tests/test_utils.py
@@ -210,13 +210,10 @@ class TestUtils(LoggedTestCase):
)
# check with preserve case
- for value, expected in samples:
- self.assertEqual(
- utils.slugify(
- "Çığ", regex_subs=subs, preserve_case=True, use_unicode=True
- ),
- "Çığ",
- )
+ self.assertEqual(
+ utils.slugify("Çığ", regex_subs=subs, preserve_case=True, use_unicode=True),
+ "Çığ",
+ )
# check normalization
samples = (
diff --git a/pelican/tools/pelican_import.py b/pelican/tools/pelican_import.py
index c9742d54..39504edb 100755
--- a/pelican/tools/pelican_import.py
+++ b/pelican/tools/pelican_import.py
@@ -1070,14 +1070,14 @@ def fields2pelican(
rc = subprocess.call(cmd, shell=True)
if rc < 0:
error = "Child was terminated by signal %d" % -rc
- exit(error)
+ sys.exit(error)
elif rc > 0:
error = "Please, check your Pandoc installation."
- exit(error)
+ sys.exit(error)
except OSError as e:
error = "Pandoc execution failed: %s" % e
- exit(error)
+ sys.exit(error)
with open(out_filename, encoding="utf-8") as fs:
content = fs.read()
@@ -1222,18 +1222,18 @@ def main():
"You must provide one of --blogger, --dotclear, "
"--medium, --tumblr, --wpfile or --feed options"
)
- exit(error)
+ sys.exit(error)
if not os.path.exists(args.output):
try:
os.mkdir(args.output)
except OSError:
error = "Unable to create the output folder: " + args.output
- exit(error)
+ sys.exit(error)
if args.wp_attach and input_type != "wordpress":
error = "You must be importing a wordpress xml to use the --wp-attach option"
- exit(error)
+ sys.exit(error)
if input_type == "blogger":
fields = blogger2fields(args.input)
diff --git a/pelican/utils.py b/pelican/utils.py
index b33eaa22..43acdd7f 100644
--- a/pelican/utils.py
+++ b/pelican/utils.py
@@ -483,7 +483,7 @@ class _HTMLWordTruncator(HTMLParser):
def getoffset(self) -> int:
line_start = 0
lineno, line_offset = self.getpos()
- for i in range(lineno - 1):
+ for _ in range(lineno - 1):
line_start = self.rawdata.index("\n", line_start) + 1
return line_start + line_offset
diff --git a/pelican/writers.py b/pelican/writers.py
index 683ae30b..91b1caeb 100644
--- a/pelican/writers.py
+++ b/pelican/writers.py
@@ -259,7 +259,7 @@ class Writer:
}
# generated pages, and write
- for page_num in range(list(paginators.values())[0].num_pages):
+ for page_num in range(next(iter(paginators.values())).num_pages):
paginated_kwargs = kwargs.copy()
for key in paginators.keys():
paginator = paginators[key]
From fc45791da48d363900a202388ffed68d6d705ded Mon Sep 17 00:00:00 2001
From: boxydog
Date: Fri, 31 May 2024 10:41:09 -0500
Subject: [PATCH 03/52] Fix or ignore ruff T201, RUF001, PLR2004, B904,
SLOT000, PYI024, PIE800
---
pyproject.toml | 21 +++++++++++++--------
1 file changed, 13 insertions(+), 8 deletions(-)
diff --git a/pyproject.toml b/pyproject.toml
index 606a05ba..ccd75f9f 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -168,11 +168,8 @@ select = [
ignore = [
# suppression in order of # of violations in Dec 2023:
- "T201", # print
"PLW2901", # redefined-loop-name
"SLF001", # private-member-access
- "RUF001", # ambiguous-unicode-character-string
- "PLR2004", # magic-value-comparison
"PLR0912", # too-many-branches
"PLR0913", # too-many-arguments
# RUF005: this is a different style of concatenating literals. It perhaps performs
@@ -193,15 +190,10 @@ ignore = [
# either by removing them from the `select` or `extend-select` configuration,
# or adding them to the `ignore` configuration."
"ISC001", # single-line-implicit-string-concatenation
- "B904", # raise-without-from-inside-except
"UP031", # printf-string-formatting
# PERF203 has minimal performance impact, and you have to catch the exception
# inside the loop if you want to ignore it, so let's ignore PERF203.
"PERF203", # try-except-in-loop
- # TODO: these only have one violation each in Dec 2023:
- "SLOT000", # no-slots-in-str-subclass
- "PYI024", # collections-named-tuple
- "PIE800", # unnecessary-spread
]
[tool.ruff.lint.extend-per-file-ignores]
@@ -210,3 +202,16 @@ ignore = [
# allow imports after a call to a function, see the file
"E402"
]
+"pelican/tests/test_utils.py" = [
+ # the tests have a bunch of unicode characters
+ "RUF001"
+]
+"pelican/tests/test_generators.py" = [
+ # the tests have a bunch of constants, why not
+ "PLR2004"
+]
+
+"pelican/tools/*.py}" = [
+ # this is a command-line utility, prints are fine
+ "T201"
+]
From 82b48fcfa12a0fc02c82172f47440870de10ead2 Mon Sep 17 00:00:00 2001
From: boxydog
Date: Fri, 31 May 2024 10:41:24 -0500
Subject: [PATCH 04/52] Fixes in files for ruff T201, RUF001, PLR2004, B904,
SLOT000, PYI024, PIE800
---
docs/conf.py | 2 +-
pelican/__init__.py | 4 ++--
pelican/generators.py | 2 +-
pelican/paginator.py | 2 +-
pelican/server.py | 14 ++++++--------
pelican/tests/test_importer.py | 4 ++--
pelican/tools/pelican_quickstart.py | 2 +-
pelican/utils.py | 8 ++++----
8 files changed, 18 insertions(+), 20 deletions(-)
diff --git a/docs/conf.py b/docs/conf.py
index 8d8078a2..8f14a018 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -29,7 +29,7 @@ source_suffix = ".rst"
master_doc = "index"
project = project_data.get("name").upper()
year = datetime.datetime.now().date().year
-copyright = f"2010–{year}"
+copyright = f"2010–{year}" # noqa: RUF001
exclude_patterns = ["_build"]
release = project_data.get("version")
version = ".".join(release.split(".")[:1])
diff --git a/pelican/__init__.py b/pelican/__init__.py
index ab6b0225..20d17706 100644
--- a/pelican/__init__.py
+++ b/pelican/__init__.py
@@ -294,7 +294,7 @@ class ParseOverrides(argparse.Action):
raise ValueError(
"Extra settings must be specified as KEY=VALUE pairs "
f"but you specified {item}"
- )
+ ) from None
try:
overrides[k] = json.loads(v)
except json.decoder.JSONDecodeError:
@@ -305,7 +305,7 @@ class ParseOverrides(argparse.Action):
"Use -e KEY='\"string\"' to specify a string value; "
"-e KEY=null to specify None; "
"-e KEY=false (or true) to specify False (or True)."
- )
+ ) from None
setattr(namespace, self.dest, overrides)
diff --git a/pelican/generators.py b/pelican/generators.py
index fdcc62ce..a2bf2f44 100644
--- a/pelican/generators.py
+++ b/pelican/generators.py
@@ -1040,7 +1040,7 @@ class StaticGenerator(Generator):
save_as = os.path.join(self.output_path, staticfile.save_as)
s_mtime = os.path.getmtime(source_path)
d_mtime = os.path.getmtime(save_as)
- return s_mtime - d_mtime > 0.000001
+ return s_mtime - d_mtime > 0.000001 # noqa: PLR2004
def _link_or_copy_staticfile(self, sc):
if self.settings["STATIC_CREATE_LINKS"]:
diff --git a/pelican/paginator.py b/pelican/paginator.py
index 92cb26b1..4a7c1aa2 100644
--- a/pelican/paginator.py
+++ b/pelican/paginator.py
@@ -5,7 +5,7 @@ from collections import namedtuple
from math import ceil
logger = logging.getLogger(__name__)
-PaginationRule = namedtuple(
+PaginationRule = namedtuple( # noqa: PYI024
"PaginationRule",
"min_page URL SAVE_AS",
)
diff --git a/pelican/server.py b/pelican/server.py
index 71cd2d81..ebf13677 100644
--- a/pelican/server.py
+++ b/pelican/server.py
@@ -53,14 +53,12 @@ class ComplexHTTPRequestHandler(server.SimpleHTTPRequestHandler):
extensions_map = {
**server.SimpleHTTPRequestHandler.extensions_map,
- **{
- # web fonts
- ".oft": "font/oft",
- ".sfnt": "font/sfnt",
- ".ttf": "font/ttf",
- ".woff": "font/woff",
- ".woff2": "font/woff2",
- },
+ # web fonts
+ ".oft": "font/oft",
+ ".sfnt": "font/sfnt",
+ ".ttf": "font/ttf",
+ ".woff": "font/woff",
+ ".woff2": "font/woff2",
}
def translate_path(self, path):
diff --git a/pelican/tests/test_importer.py b/pelican/tests/test_importer.py
index b00970f4..0349a175 100644
--- a/pelican/tests/test_importer.py
+++ b/pelican/tests/test_importer.py
@@ -376,7 +376,7 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
test_post = filter(lambda p: p[0].startswith("Post with raw data"), self.posts)
with temporary_folder() as temp:
md = next(r(f) for f in silent_f2p(test_post, "markdown", temp))
- escaped_quotes = re.search(r'\\[\'"“”‘’]', md)
+ escaped_quotes = re.search(r'\\[\'"“”‘’]', md) # noqa: RUF001
self.assertFalse(escaped_quotes)
def test_convert_caption_to_figure(self):
@@ -505,7 +505,7 @@ class TestWordpressXMLAttachements(TestCaseWithCLocale):
def test_recognise_attachments(self):
self.assertTrue(self.attachments)
- self.assertTrue(len(self.attachments.keys()) == 3)
+ self.assertEqual(3, len(self.attachments.keys()))
def test_attachments_associated_with_correct_post(self):
self.assertTrue(self.attachments)
diff --git a/pelican/tools/pelican_quickstart.py b/pelican/tools/pelican_quickstart.py
index 2f62e4bc..9be107d0 100755
--- a/pelican/tools/pelican_quickstart.py
+++ b/pelican/tools/pelican_quickstart.py
@@ -79,7 +79,7 @@ _TZ_URL = "https://en.wikipedia.org/wiki/List_of_tz_database_time_zones"
# Create a 'marked' default path, to determine if someone has supplied
# a path on the command-line.
-class _DEFAULT_PATH_TYPE(str):
+class _DEFAULT_PATH_TYPE(str): # noqa: SLOT000
is_default_path = True
diff --git a/pelican/utils.py b/pelican/utils.py
index 43acdd7f..6dc4825e 100644
--- a/pelican/utils.py
+++ b/pelican/utils.py
@@ -81,7 +81,7 @@ def strftime(date: datetime.datetime, date_format: str) -> str:
# test for valid C89 directives only
if candidate[-1] in c89_directives:
# check for '-' prefix
- if len(candidate) == 3:
+ if len(candidate) == 3: # noqa: PLR2004
# '-' prefix
candidate = f"%{candidate[-1]}"
conversion = strip_zeros
@@ -232,7 +232,7 @@ def get_date(string: str) -> datetime.datetime:
try:
return dateutil.parser.parse(string, default=default)
except (TypeError, ValueError):
- raise ValueError(f"{string!r} is not a valid date")
+ raise ValueError(f"{string!r} is not a valid date") from None
@contextmanager
@@ -666,13 +666,13 @@ def process_translations(
raise TypeError(
f"Cannot unpack {translation_id}, 'translation_id' must be falsy, a"
" string or a collection of strings"
- )
+ ) from None
except AttributeError:
raise AttributeError(
f"Cannot use {translation_id} as 'translation_id', there "
"appear to be items without these metadata "
"attributes"
- )
+ ) from None
for id_vals, items in groupby(content_list, attrgetter(*translation_id)):
# prepare warning string
From 3e81af966a88ca68135aedbe51ccf93b0e59f2eb Mon Sep 17 00:00:00 2001
From: boxydog
Date: Sat, 1 Jun 2024 16:00:07 -0500
Subject: [PATCH 05/52] ruff UP031: use format specifiers instead of percent
format
---
pyproject.toml | 1 -
1 file changed, 1 deletion(-)
diff --git a/pyproject.toml b/pyproject.toml
index ccd75f9f..dd256a44 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -190,7 +190,6 @@ ignore = [
# either by removing them from the `select` or `extend-select` configuration,
# or adding them to the `ignore` configuration."
"ISC001", # single-line-implicit-string-concatenation
- "UP031", # printf-string-formatting
# PERF203 has minimal performance impact, and you have to catch the exception
# inside the loop if you want to ignore it, so let's ignore PERF203.
"PERF203", # try-except-in-loop
From 30bde3823f50b9ba8ac5996c1c46bb72031aa6b8 Mon Sep 17 00:00:00 2001
From: boxydog
Date: Sat, 1 Jun 2024 16:00:17 -0500
Subject: [PATCH 06/52] ruff UP031 in files: use format specifiers instead of
percent format
---
pelican/contents.py | 2 +-
pelican/generators.py | 4 +-
pelican/settings.py | 2 +-
pelican/tests/test_contents.py | 2 +-
pelican/tests/test_importer.py | 2 +-
pelican/tests/test_pelican.py | 3 +-
pelican/tests/test_readers.py | 3 +-
pelican/tests/test_utils.py | 4 +-
pelican/tools/pelican_import.py | 57 ++++++++++++++---------------
pelican/tools/pelican_quickstart.py | 4 +-
pelican/utils.py | 2 +-
pelican/writers.py | 12 +++---
12 files changed, 47 insertions(+), 50 deletions(-)
diff --git a/pelican/contents.py b/pelican/contents.py
index 21c66296..cf13dabc 100644
--- a/pelican/contents.py
+++ b/pelican/contents.py
@@ -250,7 +250,7 @@ class Content:
def get_url_setting(self, key: str) -> str:
if hasattr(self, "override_" + key):
return getattr(self, "override_" + key)
- key = key if self.in_default_lang else "lang_%s" % key
+ key = key if self.in_default_lang else f"lang_{key}"
return self._expand_settings(key)
def _link_replacer(self, siteurl: str, m: re.Match) -> str:
diff --git a/pelican/generators.py b/pelican/generators.py
index a2bf2f44..73b51713 100644
--- a/pelican/generators.py
+++ b/pelican/generators.py
@@ -537,9 +537,9 @@ class ArticlesGenerator(CachingGenerator):
"""Generate direct templates pages"""
for template in self.settings["DIRECT_TEMPLATES"]:
save_as = self.settings.get(
- "%s_SAVE_AS" % template.upper(), "%s.html" % template
+ f"{template.upper()}_SAVE_AS", f"{template}.html"
)
- url = self.settings.get("%s_URL" % template.upper(), "%s.html" % template)
+ url = self.settings.get(f"{template.upper()}_URL", f"{template}.html")
if not save_as:
continue
diff --git a/pelican/settings.py b/pelican/settings.py
index 214d88a3..46b761a5 100644
--- a/pelican/settings.py
+++ b/pelican/settings.py
@@ -591,7 +591,7 @@ def configure_settings(settings: Settings) -> Settings:
if os.path.exists(theme_path):
settings["THEME"] = theme_path
else:
- raise Exception("Could not find the theme %s" % settings["THEME"])
+ raise Exception("Could not find the theme {}".format(settings["THEME"]))
# standardize strings to lowercase strings
for key in ["DEFAULT_LANG"]:
diff --git a/pelican/tests/test_contents.py b/pelican/tests/test_contents.py
index d248c3bb..81f8907c 100644
--- a/pelican/tests/test_contents.py
+++ b/pelican/tests/test_contents.py
@@ -282,7 +282,7 @@ class TestPage(TestBase):
#
# Until we find some other method to test this functionality, we
# will simply skip this test.
- unittest.skip("There is no locale %s in this system." % locale)
+ unittest.skip(f"There is no locale {locale} in this system.")
def test_template(self):
# Pages default to page, metadata overwrites
diff --git a/pelican/tests/test_importer.py b/pelican/tests/test_importer.py
index 0349a175..10b0f7f6 100644
--- a/pelican/tests/test_importer.py
+++ b/pelican/tests/test_importer.py
@@ -148,7 +148,7 @@ class TestWordpressXmlImporter(TestCaseWithCLocale):
test_post = filter(lambda p: p[0].startswith("Empty Page"), self.posts)
with temporary_folder() as temp:
fname = next(iter(silent_f2p(test_post, "markdown", temp, dirpage=True)))
- self.assertTrue(fname.endswith("pages%sempty.md" % os.path.sep))
+ self.assertTrue(fname.endswith(f"pages{os.path.sep}empty.md"))
def test_dircat(self):
silent_f2p = mute(True)(fields2pelican)
diff --git a/pelican/tests/test_pelican.py b/pelican/tests/test_pelican.py
index 075f55eb..ba03b529 100644
--- a/pelican/tests/test_pelican.py
+++ b/pelican/tests/test_pelican.py
@@ -71,8 +71,7 @@ class TestPelican(LoggedTestCase):
if proc.returncode != 0:
msg = self._formatMessage(
msg,
- "%s and %s differ:\nstdout:\n%s\nstderr\n%s"
- % (left_path, right_path, out, err),
+ f"{left_path} and {right_path} differ:\nstdout:\n{out}\nstderr\n{err}",
)
raise self.failureException(msg)
diff --git a/pelican/tests/test_readers.py b/pelican/tests/test_readers.py
index 928eb263..ec366fa8 100644
--- a/pelican/tests/test_readers.py
+++ b/pelican/tests/test_readers.py
@@ -27,8 +27,7 @@ class ReaderTest(unittest.TestCase):
self.assertEqual(
value,
real_value,
- "Expected %s to have value %s, but was %s"
- % (key, value, real_value),
+ f"Expected {key} to have value {value}, but was {real_value}",
)
else:
self.fail(f"Expected {key} to have value {value}, but was not in Dict")
diff --git a/pelican/tests/test_utils.py b/pelican/tests/test_utils.py
index beda7140..f7f11ffb 100644
--- a/pelican/tests/test_utils.py
+++ b/pelican/tests/test_utils.py
@@ -721,11 +721,11 @@ class TestCopy(unittest.TestCase):
def _exist_file(self, *path):
path = os.path.join(self.root_dir, *path)
- self.assertTrue(os.path.isfile(path), "File does not exist: %s" % path)
+ self.assertTrue(os.path.isfile(path), f"File does not exist: {path}")
def _exist_dir(self, *path):
path = os.path.join(self.root_dir, *path)
- self.assertTrue(os.path.exists(path), "Directory does not exist: %s" % path)
+ self.assertTrue(os.path.exists(path), f"Directory does not exist: {path}")
def test_copy_file_same_path(self):
self._create_file("a.txt")
diff --git a/pelican/tools/pelican_import.py b/pelican/tools/pelican_import.py
index 39504edb..65517f42 100755
--- a/pelican/tools/pelican_import.py
+++ b/pelican/tools/pelican_import.py
@@ -155,7 +155,7 @@ def wp2fields(xml, wp_custpost=False):
# Use HTMLParser due to issues with BeautifulSoup 3
title = unescape(item.title.contents[0])
except IndexError:
- title = "No title [%s]" % item.find("post_name").string
+ title = "No title [{}]".format(item.find("post_name").string)
logger.warning('Post "%s" is lacking a proper title', title)
post_name = item.find("post_name").string
@@ -510,11 +510,10 @@ def tumblr2fields(api_key, blogname):
title = post.get("question")
content = (
""
- '%s'
- ": %s"
+ '{}'
+ ": {}"
"
\n"
- " %s"
- % (
+ " {}".format(
post.get("asking_name"),
post.get("asking_url"),
post.get("question"),
@@ -710,19 +709,19 @@ def build_header(
header = "{}\n{}\n".format(title, "#" * column_width(title))
if date:
- header += ":date: %s\n" % date
+ header += f":date: {date}\n"
if author:
- header += ":author: %s\n" % author
+ header += f":author: {author}\n"
if categories:
- header += ":category: %s\n" % ", ".join(categories)
+ header += ":category: {}\n".format(", ".join(categories))
if tags:
- header += ":tags: %s\n" % ", ".join(tags)
+ header += ":tags: {}\n".format(", ".join(tags))
if slug:
- header += ":slug: %s\n" % slug
+ header += f":slug: {slug}\n"
if status:
- header += ":status: %s\n" % status
+ header += f":status: {status}\n"
if attachments:
- header += ":attachments: %s\n" % ", ".join(attachments)
+ header += ":attachments: {}\n".format(", ".join(attachments))
header += "\n"
return header
@@ -732,21 +731,21 @@ def build_asciidoc_header(
):
"""Build a header from a list of fields"""
- header = "= %s\n" % title
+ header = f"= {title}\n"
if author:
- header += "%s\n" % author
+ header += f"{author}\n"
if date:
- header += "%s\n" % date
+ header += f"{date}\n"
if categories:
- header += ":category: %s\n" % ", ".join(categories)
+ header += ":category: {}\n".format(", ".join(categories))
if tags:
- header += ":tags: %s\n" % ", ".join(tags)
+ header += ":tags: {}\n".format(", ".join(tags))
if slug:
- header += ":slug: %s\n" % slug
+ header += f":slug: {slug}\n"
if status:
- header += ":status: %s\n" % status
+ header += f":status: {status}\n"
if attachments:
- header += ":attachments: %s\n" % ", ".join(attachments)
+ header += ":attachments: {}\n".format(", ".join(attachments))
header += "\n"
return header
@@ -755,21 +754,21 @@ def build_markdown_header(
title, date, author, categories, tags, slug, status=None, attachments=None
):
"""Build a header from a list of fields"""
- header = "Title: %s\n" % title
+ header = f"Title: {title}\n"
if date:
- header += "Date: %s\n" % date
+ header += f"Date: {date}\n"
if author:
- header += "Author: %s\n" % author
+ header += f"Author: {author}\n"
if categories:
- header += "Category: %s\n" % ", ".join(categories)
+ header += "Category: {}\n".format(", ".join(categories))
if tags:
- header += "Tags: %s\n" % ", ".join(tags)
+ header += "Tags: {}\n".format(", ".join(tags))
if slug:
- header += "Slug: %s\n" % slug
+ header += f"Slug: {slug}\n"
if status:
- header += "Status: %s\n" % status
+ header += f"Status: {status}\n"
if attachments:
- header += "Attachments: %s\n" % ", ".join(attachments)
+ header += "Attachments: {}\n".format(", ".join(attachments))
header += "\n"
return header
@@ -1076,7 +1075,7 @@ def fields2pelican(
error = "Please, check your Pandoc installation."
sys.exit(error)
except OSError as e:
- error = "Pandoc execution failed: %s" % e
+ error = f"Pandoc execution failed: {e}"
sys.exit(error)
with open(out_filename, encoding="utf-8") as fs:
diff --git a/pelican/tools/pelican_quickstart.py b/pelican/tools/pelican_quickstart.py
index 9be107d0..e278e3bc 100755
--- a/pelican/tools/pelican_quickstart.py
+++ b/pelican/tools/pelican_quickstart.py
@@ -220,7 +220,7 @@ needed by Pelican.
CONF["basedir"] = open(project).read().rstrip("\n")
print(
"Using project associated with current virtual environment. "
- "Will save to:\n%s\n" % CONF["basedir"]
+ "Will save to:\n{}\n".format(CONF["basedir"])
)
else:
CONF["basedir"] = os.path.abspath(
@@ -394,7 +394,7 @@ needed by Pelican.
render_jinja_template("tasks.py.jinja2", CONF, "tasks.py")
render_jinja_template("Makefile.jinja2", CONF, "Makefile")
- print("Done. Your new project is available at %s" % CONF["basedir"])
+ print("Done. Your new project is available at {}".format(CONF["basedir"]))
if __name__ == "__main__":
diff --git a/pelican/utils.py b/pelican/utils.py
index 6dc4825e..a29fdf81 100644
--- a/pelican/utils.py
+++ b/pelican/utils.py
@@ -626,7 +626,7 @@ def truncate_html_words(s: str, num: int, end_text: str = "…") -> str:
out += " " + end_text
# Close any tags still open
for tag in truncator.open_tags:
- out += "%s>" % tag
+ out += f"{tag}>"
# Return string
return out
diff --git a/pelican/writers.py b/pelican/writers.py
index 91b1caeb..1a2cf7b0 100644
--- a/pelican/writers.py
+++ b/pelican/writers.py
@@ -107,14 +107,14 @@ class Writer:
"""
if filename in self._overridden_files:
if override:
- raise RuntimeError("File %s is set to be overridden twice" % filename)
+ raise RuntimeError(f"File {filename} is set to be overridden twice")
logger.info("Skipping %s", filename)
filename = os.devnull
elif filename in self._written_files:
if override:
logger.info("Overwriting %s", filename)
else:
- raise RuntimeError("File %s is to be overwritten" % filename)
+ raise RuntimeError(f"File {filename} is to be overwritten")
if override:
self._overridden_files.add(filename)
self._written_files.add(filename)
@@ -272,10 +272,10 @@ class Writer:
)
paginated_kwargs.update(
{
- "%s_paginator" % key: paginator,
- "%s_page" % key: page,
- "%s_previous_page" % key: previous_page,
- "%s_next_page" % key: next_page,
+ f"{key}_paginator": paginator,
+ f"{key}_page": page,
+ f"{key}_previous_page": previous_page,
+ f"{key}_next_page": next_page,
}
)
From b77bb690e260a84879b7980c58d858244f556d31 Mon Sep 17 00:00:00 2001
From: boxydog
Date: Sat, 1 Jun 2024 18:13:05 -0500
Subject: [PATCH 07/52] Improve test coverage, docs, and .gitignore
---
.coveragerc | 4 +-
.gitignore | 6 +++
docs/contribute.rst | 28 ++++++++++++++
.../article_with_md_extension.md | 1 +
pelican/tests/test_pelican.py | 37 ++++++++++++++++++-
5 files changed, 73 insertions(+), 3 deletions(-)
create mode 120000 pelican/tests/simple_content/article_with_md_extension.md
diff --git a/.coveragerc b/.coveragerc
index fdd2cad6..6347d80b 100644
--- a/.coveragerc
+++ b/.coveragerc
@@ -1,2 +1,4 @@
[report]
-omit = pelican/tests/*
+omit =
+ pelican/tests/*
+ pelican/signals.py
diff --git a/.gitignore b/.gitignore
index 473efea2..65e4d759 100644
--- a/.gitignore
+++ b/.gitignore
@@ -18,3 +18,9 @@ samples/output
*.lock
.pdm-python
.venv
+
+# direnv
+.envrc
+
+# pycharm
+.idea
diff --git a/docs/contribute.rst b/docs/contribute.rst
index 6a5a417e..419ba80f 100644
--- a/docs/contribute.rst
+++ b/docs/contribute.rst
@@ -64,6 +64,20 @@ your bug fix or feature::
Now you can make changes to Pelican, its documentation, and/or other aspects of
the project.
+Setting up git blame
+--------------------
+
+``git blame`` annotates lines from a file with information about the pull request
+that last modified it. Sweeping shallow changes (like formatting) can make that
+information less useful, so we keep a list of such changes to be ignored. To set
+that up in your repository::
+
+ git config blame.ignoreRevsFile .git-blame-ignore-revs
+
+For more information, see here_.
+
+.. _here: https://www.michaelheap.com/git-ignore-rev/
+
Running the test suite
----------------------
@@ -108,6 +122,20 @@ environments.
.. _Tox: https://tox.readthedocs.io/en/latest/
+Running a code coverage report
+------------------------------
+
+The code is more likely to stay robust if it is tested.
+coverage_ is a library that measures how much of the code is tested.
+To run it::
+
+ invoke coverage
+ open htmlcov/index.html
+
+The HTML will show overall coverage, coverage per file, and even line-by-line coverage.
+
+.. _coverage: https://github.com/nedbat/coveragepy
+
Building the docs
-----------------
diff --git a/pelican/tests/simple_content/article_with_md_extension.md b/pelican/tests/simple_content/article_with_md_extension.md
new file mode 120000
index 00000000..00a11ad3
--- /dev/null
+++ b/pelican/tests/simple_content/article_with_md_extension.md
@@ -0,0 +1 @@
+../content/article_with_md_extension.md
\ No newline at end of file
diff --git a/pelican/tests/test_pelican.py b/pelican/tests/test_pelican.py
index 075f55eb..2bea1e4e 100644
--- a/pelican/tests/test_pelican.py
+++ b/pelican/tests/test_pelican.py
@@ -1,3 +1,5 @@
+import contextlib
+import io
import locale
import logging
import os
@@ -6,9 +8,12 @@ import sys
import unittest
from collections.abc import Sequence
from shutil import rmtree
-from tempfile import mkdtemp
+from tempfile import TemporaryDirectory, mkdtemp
+from unittest.mock import patch
-from pelican import Pelican
+from rich.console import Console
+
+from pelican import Pelican, __version__, main
from pelican.generators import StaticGenerator
from pelican.settings import read_settings
from pelican.tests.support import (
@@ -271,3 +276,31 @@ class TestPelican(LoggedTestCase):
[sys.executable, "-m", "pelican", "--help"]
).decode("ascii", "replace")
assert "usage:" in output
+
+ def test_main_version(self):
+ """Run main --version."""
+ out = io.StringIO()
+ with contextlib.redirect_stdout(out):
+ with self.assertRaises(SystemExit):
+ main(["--version"])
+ self.assertEqual(f"{__version__}\n", out.getvalue())
+
+ def test_main_help(self):
+ """Run main --help."""
+ out = io.StringIO()
+ with contextlib.redirect_stdout(out):
+ with self.assertRaises(SystemExit):
+ main(["--help"])
+ self.assertIn("A tool to generate a static blog", out.getvalue())
+
+ def test_main_on_content(self):
+ """Invoke main on simple_content directory."""
+ out, err = io.StringIO(), io.StringIO()
+ with contextlib.redirect_stdout(out), contextlib.redirect_stderr(err):
+ with TemporaryDirectory() as temp_dir:
+ # Don't highlight anything.
+ # See https://rich.readthedocs.io/en/stable/highlighting.html
+ with patch("pelican.console", new=Console(highlight=False)):
+ main(["-o", temp_dir, "pelican/tests/simple_content"])
+ self.assertIn("Processed 1 article", out.getvalue())
+ self.assertEqual("", err.getvalue())
From af9865d31751c2bbe783cfc1e23fafed5e216129 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Sun, 2 Jun 2024 09:01:21 +0200
Subject: [PATCH 08/52] Ignore Ruff UP031 fixes in `git blame`
---
.git-blame-ignore-revs | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs
index f98a3dca..ac9f882e 100644
--- a/.git-blame-ignore-revs
+++ b/.git-blame-ignore-revs
@@ -15,3 +15,5 @@ db241feaa445375dc05e189e69287000ffe5fa8e
7577dd7603f7cb3a09922d1edb65b6eafb6e2ac7
# Indent Jinja templates, HTML, CSS, and JS via DjHTML
4af40e80772a58eac8969360e5caeb99e3e26e78
+# Ruff UP031: Use F-string format specifiers instead of percent format
+30bde3823f50b9ba8ac5996c1c46bb72031aa6b8
From 8c7c29e4f2a35124f2bfe7905fd0a5a334f7e056 Mon Sep 17 00:00:00 2001
From: boxydog <93335439+boxydog@users.noreply.github.com>
Date: Sun, 2 Jun 2024 14:03:56 -0500
Subject: [PATCH 09/52] Add dependabot checking (#5)
---
.github/dependabot.yml | 10 ++++++++++
1 file changed, 10 insertions(+)
create mode 100644 .github/dependabot.yml
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index 00000000..5968b41d
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,10 @@
+# See https://docs.github.com/en/free-pro-team@latest/
+# github/administering-a-repository/enabling-and-disabling-version-updates
+
+version: 2
+updates:
+ - package-ecosystem: "pip"
+ directory: "/"
+ schedule:
+ interval: "monthly"
+ open-pull-requests-limit: 10
From fd955ba05497c8add703fdb9d0e9788fc1aa90bf Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Sun, 16 Jun 2024 19:16:58 +0200
Subject: [PATCH 10/52] Show missing line numbers via `invoke coverage`
Also includes a change that causes this command to return a failing
status when coverage drops below its current value of 74.8%.
---
tasks.py | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/tasks.py b/tasks.py
index 64409e20..9a7564b2 100644
--- a/tasks.py
+++ b/tasks.py
@@ -47,7 +47,11 @@ def tests(c):
@task
def coverage(c):
"""Generate code coverage of running the test suite."""
- c.run(f"{VENV_BIN}/pytest --cov=pelican", pty=PTY)
+ c.run(
+ f"{VENV_BIN}/pytest --cov=pelican --cov-report term-missing "
+ "--cov-fail-under 74.8",
+ pty=PTY,
+ )
c.run(f"{VENV_BIN}/coverage html", pty=PTY)
From e262990c689c6895a4724a7fd2c42412a8dca6a6 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Sun, 16 Jun 2024 19:23:46 +0200
Subject: [PATCH 11/52] Tweak docs about test coverage and `git blame`
---
docs/contribute.rst | 36 ++++++++++++++++++++++--------------
1 file changed, 22 insertions(+), 14 deletions(-)
diff --git a/docs/contribute.rst b/docs/contribute.rst
index 419ba80f..07cf998a 100644
--- a/docs/contribute.rst
+++ b/docs/contribute.rst
@@ -64,19 +64,26 @@ your bug fix or feature::
Now you can make changes to Pelican, its documentation, and/or other aspects of
the project.
-Setting up git blame
---------------------
+Setting up ``git blame`` (optional)
+-----------------------------------
-``git blame`` annotates lines from a file with information about the pull request
-that last modified it. Sweeping shallow changes (like formatting) can make that
-information less useful, so we keep a list of such changes to be ignored. To set
-that up in your repository::
+``git blame`` annotates lines in a file with information about the pull request
+that last modified it. Sweeping shallow changes (like formatting) can make that
+information less useful, so we keep a list of such changes to be ignored. Run the
+following command to set this up in your repository, adding ``--global`` if you
+want this setting to apply to all repositories::
git config blame.ignoreRevsFile .git-blame-ignore-revs
-For more information, see here_.
+As noted in a `useful article`_ about ``git blame``, there are other related
+settings you may find to be beneficial::
-.. _here: https://www.michaelheap.com/git-ignore-rev/
+ # Add `?` to any lines that have had a commit skipped using --ignore-rev
+ git config --global blame.markIgnoredLines true
+ # Add `*` to any lines that were added in a skipped commit and can not be attributed
+ git config --global blame.markUnblamableLines true
+
+.. _useful article: https://www.michaelheap.com/git-ignore-rev/
Running the test suite
----------------------
@@ -125,16 +132,17 @@ environments.
Running a code coverage report
------------------------------
-The code is more likely to stay robust if it is tested.
-coverage_ is a library that measures how much of the code is tested.
-To run it::
+Code is more likely to stay robust if it is tested. Coverage_ is a library that
+measures how much of the code is tested. To run it::
invoke coverage
+
+This will show overall coverage, coverage per file, and even line-by-line coverage.
+There is also an HTML report available::
+
open htmlcov/index.html
-The HTML will show overall coverage, coverage per file, and even line-by-line coverage.
-
-.. _coverage: https://github.com/nedbat/coveragepy
+.. _Coverage: https://github.com/nedbat/coveragepy
Building the docs
-----------------
From b80a592d305834b08735b4aa10c050b4e77f15da Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Sun, 16 Jun 2024 19:37:23 +0200
Subject: [PATCH 12/52] Lower minimum coverage required in `invoke coverage`
---
tasks.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tasks.py b/tasks.py
index 9a7564b2..3a1722eb 100644
--- a/tasks.py
+++ b/tasks.py
@@ -49,7 +49,7 @@ def coverage(c):
"""Generate code coverage of running the test suite."""
c.run(
f"{VENV_BIN}/pytest --cov=pelican --cov-report term-missing "
- "--cov-fail-under 74.8",
+ "--cov-fail-under 74",
pty=PTY,
)
c.run(f"{VENV_BIN}/coverage html", pty=PTY)
From dc40474e29f5bd3c32a354377ea666908016db41 Mon Sep 17 00:00:00 2001
From: Sean Hammond
Date: Tue, 11 Jun 2024 19:38:08 +0100
Subject: [PATCH 13/52] Use Dependabot to keep GitHub Actions up to date
Configure Dependabot to send automated PRs to update the version numbers
in `.github/workflows/*.yml` when new versions of actions are released.
See:
https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot
---
.github/dependabot.yml | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
index 5968b41d..a0a90b94 100644
--- a/.github/dependabot.yml
+++ b/.github/dependabot.yml
@@ -8,3 +8,7 @@ updates:
schedule:
interval: "monthly"
open-pull-requests-limit: 10
+ - package-ecosystem: "github-actions"
+ directory: "/"
+ schedule:
+ interval: "monthly"
From e46595cdacc57d8a76e8945c7aab5e28686b7f9d Mon Sep 17 00:00:00 2001
From: Sean Hammond
Date: Tue, 11 Jun 2024 20:03:12 +0100
Subject: [PATCH 14/52] Add theme, Python version, siteurl and feed_domain to
GitHub Pages deployment workflow
Add theme, Python version, siteurl and feed_domain support to the
reusable GitHub Actions workflow for deploying a Pelican site to GitHub
Pages:
1. Add a new `theme` option to the workflow that callers can use to
specify an external theme to be checked out and used
2. Add a new `python` option to the workflow that callers can use to
specify the Python version, in case they need to build their site
with a particular version of Python
3. Pass `--extra-settings FEED_DOMAIN='"${{ steps.pages.outputs.base_url }}"'`
to the `pelican` command to set the value of Pelican's `FEED_DOMAIN`
setting for feed URLs.
4. Add a `feed_domain` input to the workflow so that users can override
the feed domain if they need to.
5. Add a `siteurl` input to the workflow so that users can override the
site URL if they need to.
6. Add a note to the docs about GitHub Pages generating http:// URLs for
https:// sites, and how to fix it
7. Some light editing of the docs for the workflow
---
.github/workflows/github_pages.yml | 43 +++++++++++++--
docs/tips.rst | 88 +++++++++++++++++++++---------
2 files changed, 100 insertions(+), 31 deletions(-)
diff --git a/.github/workflows/github_pages.yml b/.github/workflows/github_pages.yml
index f4a01b92..efe6959c 100644
--- a/.github/workflows/github_pages.yml
+++ b/.github/workflows/github_pages.yml
@@ -17,6 +17,26 @@ on:
default: "output/"
description: "Where to output the generated files (`pelican`'s `--output` option)"
type: string
+ theme:
+ required: false
+ default: ""
+ description: "The GitHub repo URL of a custom theme to use, for example: 'https://github.com/seanh/sidecar.git'"
+ type: string
+ python:
+ required: false
+ default: "3.12"
+ description: "The version of Python to use, for example: '3.12' (to use the most recent version of Python 3.12, this is faster) or '3.12.1' (to use an exact version, slower)"
+ type: string
+ siteurl:
+ required: false
+ default: ""
+ description: "The base URL of your web site (Pelican's SITEURL setting). If not passed this will default to the URL of your GitHub Pages site, which is correct in most cases."
+ type: string
+ feed_domain:
+ required: false
+ default: ""
+ description: "The domain to be prepended to feed URLs (Pelican's FEED_DOMAIN setting). If not passed this will default to the URL of your GitHub Pages site, which is correct in most cases."
+ type: string
permissions:
contents: read
pages: write
@@ -33,18 +53,31 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v4
with:
- python-version: "3.11"
+ python-version: ${{ inputs.python }}
+ - name: Checkout theme
+ if: ${{ inputs.theme }}
+ run: git clone '${{ inputs.theme }}' .theme
- name: Configure GitHub Pages
id: pages
uses: actions/configure-pages@v3
- name: Install requirements
run: pip install ${{ inputs.requirements }}
- name: Build Pelican site
+ shell: python
run: |
- pelican \
- --settings "${{ inputs.settings }}" \
- --extra-settings SITEURL='"${{ steps.pages.outputs.base_url }}"' \
- --output "${{ inputs.output-path }}"
+ import subprocess
+
+ cmd = "pelican"
+ cmd += " --settings ${{ inputs.settings }}"
+ cmd += " --extra-settings"
+ cmd += """ SITEURL='"${{ inputs.siteurl || steps.pages.outputs.base_url }}"'"""
+ cmd += """ FEED_DOMAIN='"${{ inputs.feed_domain || steps.pages.outputs.base_url }}"'"""
+ cmd += " --output ${{ inputs.output-path }}"
+
+ if "${{ inputs.theme }}":
+ cmd += " --theme-path .theme"
+
+ subprocess.run(cmd, shell=True, check=True)
- name: Fix permissions
run: |
chmod -c -R +rX "${{ inputs.output-path }}" | while read line; do
diff --git a/docs/tips.rst b/docs/tips.rst
index 3344900d..5d75e4fb 100644
--- a/docs/tips.rst
+++ b/docs/tips.rst
@@ -163,8 +163,8 @@ Pelican-powered sites can be published to GitHub Pages via a `custom workflow
Notes:
-* You don't need to set ``SITEURL`` in your Pelican settings: the workflow will
- set it for you
+* You don't need to set ``SITEURL`` or ``FEED_DOMAIN`` in your Pelican
+ settings: the workflow will set them correctly for you
* You don't need to commit your ``--output`` / ``OUTPUT_PATH`` directory
(``output/``) to git: the workflow will run ``pelican`` to build the output
@@ -174,36 +174,72 @@ See `GitHub's docs about reusable workflows
Date: Mon, 17 Jun 2024 08:11:21 -0500
Subject: [PATCH 15/52] Log warnings about files that would have been processed
by disabled readers
---
pelican/__init__.py | 5 +++--
pelican/generators.py | 27 +++++++++++++++++++++++-
pelican/readers.py | 39 ++++++++++++++++++++++++++++++-----
pelican/tests/test_pelican.py | 24 ++++++++++++++++++++-
pelican/tests/test_readers.py | 15 +++++++++++++-
pelican/tests/test_utils.py | 7 +++++++
pelican/utils.py | 15 +++++++++++---
7 files changed, 119 insertions(+), 13 deletions(-)
diff --git a/pelican/__init__.py b/pelican/__init__.py
index 20d17706..96849bae 100644
--- a/pelican/__init__.py
+++ b/pelican/__init__.py
@@ -30,7 +30,6 @@ from pelican.generators import (
)
from pelican.plugins import signals
from pelican.plugins._utils import get_plugin_name, load_plugins
-from pelican.readers import Readers
from pelican.server import ComplexHTTPRequestHandler, RootedHTTPServer
from pelican.settings import read_settings
from pelican.utils import clean_output_dir, maybe_pluralize, wait_for_changes
@@ -126,6 +125,8 @@ class Pelican:
for p in generators:
if hasattr(p, "generate_context"):
p.generate_context()
+ if hasattr(p, "check_disabled_readers"):
+ p.check_disabled_readers()
# for plugins that create/edit the summary
logger.debug("Signal all_generators_finalized.send()")
@@ -573,7 +574,7 @@ def autoreload(args, excqueue=None):
try:
pelican.run()
- changed_files = wait_for_changes(args.settings, Readers, settings)
+ changed_files = wait_for_changes(args.settings, settings)
changed_files = {c[1] for c in changed_files}
if settings_file in changed_files:
diff --git a/pelican/generators.py b/pelican/generators.py
index 73b51713..548c494f 100644
--- a/pelican/generators.py
+++ b/pelican/generators.py
@@ -7,6 +7,7 @@ from collections import defaultdict
from functools import partial
from itertools import chain, groupby
from operator import attrgetter
+from typing import List, Optional, Set
from jinja2 import (
BaseLoader,
@@ -156,7 +157,9 @@ class Generator:
return False
- def get_files(self, paths, exclude=None, extensions=None):
+ def get_files(
+ self, paths, exclude: Optional[List[str]] = None, extensions=None
+ ) -> Set[str]:
"""Return a list of files to use, based on rules
:param paths: the list pf paths to search (relative to self.path)
@@ -250,6 +253,13 @@ class Generator:
# return the name of the class for logging purposes
return self.__class__.__name__
+ def _check_disabled_readers(self, paths, exclude: Optional[List[str]]) -> None:
+ """Log warnings for files that would have been processed by disabled readers."""
+ for fil in self.get_files(
+ paths, exclude=exclude, extensions=self.readers.disabled_extensions
+ ):
+ self.readers.check_file(fil)
+
class CachingGenerator(Generator, FileStampDataCacher):
"""Subclass of Generator and FileStampDataCacher classes
@@ -643,6 +653,11 @@ class ArticlesGenerator(CachingGenerator):
self.generate_authors(write)
self.generate_drafts(write)
+ def check_disabled_readers(self) -> None:
+ self._check_disabled_readers(
+ self.settings["ARTICLE_PATHS"], exclude=self.settings["ARTICLE_EXCLUDES"]
+ )
+
def generate_context(self):
"""Add the articles into the shared context"""
@@ -849,6 +864,11 @@ class PagesGenerator(CachingGenerator):
super().__init__(*args, **kwargs)
signals.page_generator_init.send(self)
+ def check_disabled_readers(self) -> None:
+ self._check_disabled_readers(
+ self.settings["PAGE_PATHS"], exclude=self.settings["PAGE_EXCLUDES"]
+ )
+
def generate_context(self):
all_pages = []
hidden_pages = []
@@ -953,6 +973,11 @@ class StaticGenerator(Generator):
self.fallback_to_symlinks = False
signals.static_generator_init.send(self)
+ def check_disabled_readers(self) -> None:
+ self._check_disabled_readers(
+ self.settings["STATIC_PATHS"], exclude=self.settings["STATIC_EXCLUDES"]
+ )
+
def generate_context(self):
self.staticfiles = []
linked_files = set(self.context["static_links"])
diff --git a/pelican/readers.py b/pelican/readers.py
index 422f39fc..ee7e3466 100644
--- a/pelican/readers.py
+++ b/pelican/readers.py
@@ -17,7 +17,7 @@ from pelican import rstdirectives # NOQA
from pelican.cache import FileStampDataCacher
from pelican.contents import Author, Category, Page, Tag
from pelican.plugins import signals
-from pelican.utils import get_date, pelican_open, posixize_path
+from pelican.utils import file_suffix, get_date, pelican_open, posixize_path
try:
from markdown import Markdown
@@ -125,6 +125,10 @@ class BaseReader:
metadata = {}
return content, metadata
+ def disabled_message(self) -> str:
+ """Message about why this plugin was disabled."""
+ return ""
+
class _FieldBodyTranslator(HTMLTranslator):
def __init__(self, document):
@@ -347,6 +351,12 @@ class MarkdownReader(BaseReader):
metadata = {}
return content, metadata
+ def disabled_message(self) -> str:
+ return (
+ "Could not import markdown.Markdown. "
+ "Have you installed the markdown package?"
+ )
+
class HTMLReader(BaseReader):
"""Parses HTML files as input, looking for meta, title, and body tags"""
@@ -508,17 +518,23 @@ class Readers(FileStampDataCacher):
def __init__(self, settings=None, cache_name=""):
self.settings = settings or {}
self.readers = {}
+ self.disabled_readers = {}
+ # extension => reader for readers that are enabled
self.reader_classes = {}
+ # extension => reader for readers that are not enabled
+ disabled_reader_classes = {}
for cls in [BaseReader] + BaseReader.__subclasses__():
if not cls.enabled:
logger.debug(
"Missing dependencies for %s", ", ".join(cls.file_extensions)
)
- continue
for ext in cls.file_extensions:
- self.reader_classes[ext] = cls
+ if cls.enabled:
+ self.reader_classes[ext] = cls
+ else:
+ disabled_reader_classes[ext] = cls
if self.settings["READERS"]:
self.reader_classes.update(self.settings["READERS"])
@@ -531,6 +547,9 @@ class Readers(FileStampDataCacher):
self.readers[fmt] = reader_class(self.settings)
+ for fmt, reader_class in disabled_reader_classes.items():
+ self.disabled_readers[fmt] = reader_class(self.settings)
+
# set up caching
cache_this_level = (
cache_name != "" and self.settings["CONTENT_CACHING_LAYER"] == "reader"
@@ -541,8 +560,13 @@ class Readers(FileStampDataCacher):
@property
def extensions(self):
+ """File extensions that will be processed by a reader."""
return self.readers.keys()
+ @property
+ def disabled_extensions(self):
+ return self.disabled_readers.keys()
+
def read_file(
self,
base_path,
@@ -562,8 +586,7 @@ class Readers(FileStampDataCacher):
logger.debug("Read file %s -> %s", source_path, content_class.__name__)
if not fmt:
- _, ext = os.path.splitext(os.path.basename(path))
- fmt = ext[1:]
+ fmt = file_suffix(path)
if fmt not in self.readers:
raise TypeError("Pelican does not know how to parse %s", path)
@@ -654,6 +677,12 @@ class Readers(FileStampDataCacher):
context=context,
)
+ def check_file(self, source_path: str) -> None:
+ """Log a warning if a file is processed by a disabled reader."""
+ reader = self.disabled_readers.get(file_suffix(source_path), None)
+ if reader:
+ logger.warning(f"{source_path}: {reader.disabled_message()}")
+
def find_empty_alt(content, path):
"""Find images with empty alt
diff --git a/pelican/tests/test_pelican.py b/pelican/tests/test_pelican.py
index add5f576..e243be61 100644
--- a/pelican/tests/test_pelican.py
+++ b/pelican/tests/test_pelican.py
@@ -9,10 +9,11 @@ import unittest
from collections.abc import Sequence
from shutil import rmtree
from tempfile import TemporaryDirectory, mkdtemp
-from unittest.mock import patch
+from unittest.mock import PropertyMock, patch
from rich.console import Console
+import pelican.readers
from pelican import Pelican, __version__, main
from pelican.generators import StaticGenerator
from pelican.settings import read_settings
@@ -303,3 +304,24 @@ class TestPelican(LoggedTestCase):
main(["-o", temp_dir, "pelican/tests/simple_content"])
self.assertIn("Processed 1 article", out.getvalue())
self.assertEqual("", err.getvalue())
+
+ def test_main_on_content_markdown_disabled(self):
+ """Invoke main on simple_content directory."""
+ with patch.object(
+ pelican.readers.MarkdownReader, "enabled", new_callable=PropertyMock
+ ) as attr_mock:
+ attr_mock.return_value = False
+ out, err = io.StringIO(), io.StringIO()
+ with contextlib.redirect_stdout(out), contextlib.redirect_stderr(err):
+ with TemporaryDirectory() as temp_dir:
+ # Don't highlight anything.
+ # See https://rich.readthedocs.io/en/stable/highlighting.html
+ with patch("pelican.console", new=Console(highlight=False)):
+ main(["-o", temp_dir, "pelican/tests/simple_content"])
+ self.assertIn("Processed 0 articles", out.getvalue())
+ self.assertLogCountEqual(
+ 1,
+ ".*article_with_md_extension.md: "
+ "Could not import markdown.Markdown. "
+ "Have you installed the markdown package?",
+ )
diff --git a/pelican/tests/test_readers.py b/pelican/tests/test_readers.py
index ec366fa8..68938a83 100644
--- a/pelican/tests/test_readers.py
+++ b/pelican/tests/test_readers.py
@@ -1,5 +1,5 @@
import os
-from unittest.mock import patch
+from unittest.mock import PropertyMock, patch
from pelican import readers
from pelican.tests.support import get_settings, unittest
@@ -32,6 +32,19 @@ class ReaderTest(unittest.TestCase):
else:
self.fail(f"Expected {key} to have value {value}, but was not in Dict")
+ def test_markdown_disabled(self):
+ with patch.object(
+ readers.MarkdownReader, "enabled", new_callable=PropertyMock
+ ) as attr_mock:
+ attr_mock.return_value = False
+ readrs = readers.Readers(settings=get_settings())
+ self.assertEqual(
+ set(readers.MarkdownReader.file_extensions),
+ readrs.disabled_readers.keys(),
+ )
+ for val in readrs.disabled_readers.values():
+ self.assertEqual(readers.MarkdownReader, val.__class__)
+
class TestAssertDictHasSubset(ReaderTest):
def setUp(self):
diff --git a/pelican/tests/test_utils.py b/pelican/tests/test_utils.py
index f7f11ffb..0da59dd4 100644
--- a/pelican/tests/test_utils.py
+++ b/pelican/tests/test_utils.py
@@ -966,3 +966,10 @@ class TestMemoized(unittest.TestCase):
container.get.cache.clear()
self.assertEqual("bar", container.get("bar"))
get_mock.assert_called_once_with("bar")
+
+
+class TestStringUtils(unittest.TestCase):
+ def test_file_suffix(self):
+ self.assertEqual("", utils.file_suffix(""))
+ self.assertEqual("", utils.file_suffix("foo"))
+ self.assertEqual("md", utils.file_suffix("foo.md"))
diff --git a/pelican/utils.py b/pelican/utils.py
index a29fdf81..b780ab97 100644
--- a/pelican/utils.py
+++ b/pelican/utils.py
@@ -29,6 +29,7 @@ from typing import (
)
import dateutil.parser
+from watchfiles import Change
try:
from zoneinfo import ZoneInfo
@@ -39,7 +40,6 @@ from markupsafe import Markup
if TYPE_CHECKING:
from pelican.contents import Content
- from pelican.readers import Readers
from pelican.settings import Settings
logger = logging.getLogger(__name__)
@@ -797,9 +797,8 @@ def order_content(
def wait_for_changes(
settings_file: str,
- reader_class: type[Readers],
settings: Settings,
-):
+) -> set[tuple[Change, str]]:
content_path = settings.get("PATH", "")
theme_path = settings.get("THEME", "")
ignore_files = {
@@ -924,3 +923,13 @@ def temporary_locale(
locale.setlocale(lc_category, temp_locale)
yield
locale.setlocale(lc_category, orig_locale)
+
+
+def file_suffix(path: str) -> str:
+ """Return the suffix of a filename in a path."""
+ _, ext = os.path.splitext(os.path.basename(path))
+ ret = ""
+ if len(ext) > 1:
+ # drop the ".", e.g., "exe", not ".exe"
+ ret = ext[1:]
+ return ret
From 135c61f769b963efeb5cc61f9d4332fd887a0b30 Mon Sep 17 00:00:00 2001
From: Sean Hammond
Date: Mon, 17 Jun 2024 16:38:10 +0100
Subject: [PATCH 16/52] Add Dependabot to GitHub Actions workflow docs
---
docs/tips.rst | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
diff --git a/docs/tips.rst b/docs/tips.rst
index 5d75e4fb..338dbe1f 100644
--- a/docs/tips.rst
+++ b/docs/tips.rst
@@ -152,6 +152,25 @@ Pelican-powered sites can be published to GitHub Pages via a `custom workflow
with:
settings: "publishconf.py"
+ You may want to replace the ``@master`` with the ID of a specific commit in
+ this repo in order to pin the version of the reusable workflow that you're using:
+ ``uses: getpelican/pelican/.github/workflows/github_pages.yml@``.
+ If you do this you might want to get Dependabot to send you automated pull
+ requests to update that commit ID whenever new versions of this workflow are
+ published, like so:
+
+ .. code-block:: yaml
+
+ # .github/dependabot.yml
+ version: 2
+ updates:
+ - package-ecosystem: "github-actions"
+ directory: "/"
+ schedule:
+ interval: "monthly"
+
+ See `GitHub's docs about using Dependabot to keep your actions up to date `_.
+
3. Go to the **Actions** tab in your repo
(``https://github.com///actions``) and you should see a
**Deploy to GitHub Pages** action running.
From 50f77b42b2acfffbb3451aa15374726a96c1c8eb Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Mon, 17 Jun 2024 20:36:18 +0200
Subject: [PATCH 17/52] Add CODEOWNERS file to project
---
.github/CODEOWNERS | 1 +
1 file changed, 1 insertion(+)
create mode 100644 .github/CODEOWNERS
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
new file mode 100644
index 00000000..0fbd850c
--- /dev/null
+++ b/.github/CODEOWNERS
@@ -0,0 +1 @@
+.github/workflows/github_pages.yml @seanh
From d03ae2a41fc813f8b8ee0d8df46d8b9e18bb0d20 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 17 Jun 2024 11:44:06 +0000
Subject: [PATCH 18/52] Bump actions/upload-pages-artifact from 2 to 3
Bumps [actions/upload-pages-artifact](https://github.com/actions/upload-pages-artifact) from 2 to 3.
- [Release notes](https://github.com/actions/upload-pages-artifact/releases)
- [Commits](https://github.com/actions/upload-pages-artifact/compare/v2...v3)
---
updated-dependencies:
- dependency-name: actions/upload-pages-artifact
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot]
---
.github/workflows/github_pages.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/workflows/github_pages.yml b/.github/workflows/github_pages.yml
index efe6959c..d8a18de3 100644
--- a/.github/workflows/github_pages.yml
+++ b/.github/workflows/github_pages.yml
@@ -84,7 +84,7 @@ jobs:
echo "::warning title=Invalid file permissions automatically fixed::$line"
done
- name: Upload artifact
- uses: actions/upload-pages-artifact@v2
+ uses: actions/upload-pages-artifact@v3
with:
path: ${{ inputs.output-path }}
deploy:
From 750a1f8bfaf4d14aafd398976c55ecab332e3001 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 17 Jun 2024 18:44:01 +0000
Subject: [PATCH 19/52] Bump actions/configure-pages from 3 to 5
Bumps [actions/configure-pages](https://github.com/actions/configure-pages) from 3 to 5.
- [Release notes](https://github.com/actions/configure-pages/releases)
- [Commits](https://github.com/actions/configure-pages/compare/v3...v5)
---
updated-dependencies:
- dependency-name: actions/configure-pages
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot]
---
.github/workflows/github_pages.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/workflows/github_pages.yml b/.github/workflows/github_pages.yml
index d8a18de3..0e9eab77 100644
--- a/.github/workflows/github_pages.yml
+++ b/.github/workflows/github_pages.yml
@@ -59,7 +59,7 @@ jobs:
run: git clone '${{ inputs.theme }}' .theme
- name: Configure GitHub Pages
id: pages
- uses: actions/configure-pages@v3
+ uses: actions/configure-pages@v5
- name: Install requirements
run: pip install ${{ inputs.requirements }}
- name: Build Pelican site
From 487877f206ff124278fc53be22eb00bafc3708f4 Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 17 Jun 2024 11:44:10 +0000
Subject: [PATCH 20/52] Bump actions/deploy-pages from 2 to 4
Bumps [actions/deploy-pages](https://github.com/actions/deploy-pages) from 2 to 4.
- [Release notes](https://github.com/actions/deploy-pages/releases)
- [Commits](https://github.com/actions/deploy-pages/compare/v2...v4)
---
updated-dependencies:
- dependency-name: actions/deploy-pages
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot]
---
.github/workflows/github_pages.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/workflows/github_pages.yml b/.github/workflows/github_pages.yml
index 0e9eab77..427ad96d 100644
--- a/.github/workflows/github_pages.yml
+++ b/.github/workflows/github_pages.yml
@@ -96,4 +96,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
- uses: actions/deploy-pages@v2
+ uses: actions/deploy-pages@v4
From 617aba077f1692925dc07abaf61999e624ac922a Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Mon, 17 Jun 2024 18:44:11 +0000
Subject: [PATCH 21/52] Bump actions/setup-python from 4 to 5
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 4 to 5.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v4...v5)
---
updated-dependencies:
- dependency-name: actions/setup-python
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot]
---
.github/workflows/github_pages.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/workflows/github_pages.yml b/.github/workflows/github_pages.yml
index 427ad96d..e7f7b59a 100644
--- a/.github/workflows/github_pages.yml
+++ b/.github/workflows/github_pages.yml
@@ -51,7 +51,7 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
- uses: actions/setup-python@v4
+ uses: actions/setup-python@v5
with:
python-version: ${{ inputs.python }}
- name: Checkout theme
From 853e9e6b8a479b99217ca0f9928012eca90a7ecd Mon Sep 17 00:00:00 2001
From: Sean Hammond
Date: Mon, 17 Jun 2024 20:46:28 +0100
Subject: [PATCH 22/52] Document that feed_domain is not required
---
docs/tips.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/tips.rst b/docs/tips.rst
index 338dbe1f..c86a12f4 100644
--- a/docs/tips.rst
+++ b/docs/tips.rst
@@ -240,7 +240,7 @@ Here's the complete list of workflow inputs:
| | | Pages site, which is correct in most | | |
| | | cases. | | |
+------------------+----------+--------------------------------------------+--------+---------------+
-| ``feed_domain`` | | The domain to be prepended to feed URLs | string | The URL of |
+| ``feed_domain`` | No | The domain to be prepended to feed URLs | string | The URL of |
| | | (Pelican's ``FEED_DOMAIN`` setting). If | | your GitHub |
| | | not passed this will default to the URL of | | Pages site. |
| | | your GitHub Pages site, which is correct | | |
From 05535c7d6c274dc6e3560b70e98f73bc6d01e052 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Mon, 17 Jun 2024 22:19:21 +0200
Subject: [PATCH 23/52] Docs: GitHub Pages workflow is now supported
---
.github/workflows/github_pages.yml | 2 +-
docs/tips.rst | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/.github/workflows/github_pages.yml b/.github/workflows/github_pages.yml
index e7f7b59a..48ebb2d0 100644
--- a/.github/workflows/github_pages.yml
+++ b/.github/workflows/github_pages.yml
@@ -1,4 +1,4 @@
-# Workflow for publishing to GitHub Pages. **NO OFFICIAL SUPPORT PROVIDED.**
+# Workflow for publishing to GitHub Pages.
name: Deploy to GitHub Pages
on:
workflow_call:
diff --git a/docs/tips.rst b/docs/tips.rst
index 338dbe1f..746b5e43 100644
--- a/docs/tips.rst
+++ b/docs/tips.rst
@@ -128,7 +128,7 @@ Publishing to GitHub Pages Using a Custom GitHub Actions Workflow
Pelican-powered sites can be published to GitHub Pages via a `custom workflow
`_.
-**No official support is provided** for this community-submitted workflow. To use it:
+To use it:
1. Enable GitHub Pages in your repo: go to **Settings → Pages** and choose
**GitHub Actions** for the **Source** setting.
From 993c75103b7fccebb33dc0a148a4b9be42373d54 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 18 Jun 2024 09:04:59 +0200
Subject: [PATCH 24/52] Generate social cards in Sphinx documentation
Without `matplotlib` installed, Sphinx output says that social cards
cannot be generated.
---
requirements/docs.pip | 1 +
1 file changed, 1 insertion(+)
diff --git a/requirements/docs.pip b/requirements/docs.pip
index 7b0f37cc..4c16c84a 100644
--- a/requirements/docs.pip
+++ b/requirements/docs.pip
@@ -2,4 +2,5 @@ sphinx
sphinxext-opengraph
furo==2023.9.10
livereload
+matplotlib
tomli;python_version<"3.11"
From 49723e6daf8caf6c46ab6cb58715dfe6b7e4a40d Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 18 Jun 2024 09:08:45 +0200
Subject: [PATCH 25/52] Docs: Remove `ifconfig` Sphinx extension
Originally added in #815, something about this seems to be causing an
obscure ReadTheDocs build error.
---
docs/conf.py | 1 -
docs/index.rst | 9 ---------
2 files changed, 10 deletions(-)
diff --git a/docs/conf.py b/docs/conf.py
index 8f14a018..b812ee4c 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -21,7 +21,6 @@ with open("../pyproject.toml", "rb") as f:
templates_path = ["_templates"]
extensions = [
"sphinx.ext.autodoc",
- "sphinx.ext.ifconfig",
"sphinx.ext.extlinks",
"sphinxext.opengraph",
]
diff --git a/docs/index.rst b/docs/index.rst
index 60591482..159ea3be 100644
--- a/docs/index.rst
+++ b/docs/index.rst
@@ -1,15 +1,6 @@
Pelican |release|
=================
-
-.. ifconfig:: release.endswith('.dev')
-
- .. warning::
-
- This documentation is for the version of Pelican currently under
- development. Were you looking for version |last_stable| documentation?
-
-
Pelican is a static site generator, written in Python_. Highlights include:
* Write your content directly with your editor of choice in reStructuredText_
From 5171631dec562f8033388b52f0690aa0381bf170 Mon Sep 17 00:00:00 2001
From: Tomasz Wojdat
Date: Wed, 19 Jun 2024 00:11:28 +0200
Subject: [PATCH 26/52] chore: update URLs of GitHub Ribbons
Old URLs are no longer active. New ones were taken from GitHub blog:
https://github.blog/2008-12-19-github-ribbons/
Also update output in functional tests.
---
pelican/tests/output/custom/a-markdown-powered-article.html | 2 +-
pelican/tests/output/custom/archives.html | 2 +-
pelican/tests/output/custom/article-1.html | 2 +-
pelican/tests/output/custom/article-2.html | 2 +-
pelican/tests/output/custom/article-3.html | 2 +-
pelican/tests/output/custom/author/alexis-metaireau.html | 2 +-
pelican/tests/output/custom/author/alexis-metaireau2.html | 2 +-
pelican/tests/output/custom/author/alexis-metaireau3.html | 2 +-
pelican/tests/output/custom/authors.html | 2 +-
pelican/tests/output/custom/categories.html | 2 +-
pelican/tests/output/custom/category/bar.html | 2 +-
pelican/tests/output/custom/category/cat1.html | 2 +-
pelican/tests/output/custom/category/misc.html | 2 +-
pelican/tests/output/custom/category/yeah.html | 2 +-
.../output/custom/drafts/a-draft-article-without-date.html | 2 +-
pelican/tests/output/custom/drafts/a-draft-article.html | 2 +-
pelican/tests/output/custom/filename_metadata-example.html | 2 +-
pelican/tests/output/custom/index.html | 2 +-
pelican/tests/output/custom/index2.html | 2 +-
pelican/tests/output/custom/index3.html | 2 +-
pelican/tests/output/custom/jinja2_template.html | 2 +-
pelican/tests/output/custom/oh-yeah-fr.html | 2 +-
pelican/tests/output/custom/oh-yeah.html | 2 +-
pelican/tests/output/custom/override/index.html | 2 +-
.../tests/output/custom/pages/this-is-a-test-hidden-page.html | 2 +-
pelican/tests/output/custom/pages/this-is-a-test-page.html | 2 +-
pelican/tests/output/custom/second-article-fr.html | 2 +-
pelican/tests/output/custom/second-article.html | 2 +-
pelican/tests/output/custom/tag/bar.html | 2 +-
pelican/tests/output/custom/tag/baz.html | 2 +-
pelican/tests/output/custom/tag/foo.html | 2 +-
pelican/tests/output/custom/tag/foobar.html | 2 +-
pelican/tests/output/custom/tag/oh.html | 2 +-
pelican/tests/output/custom/tag/yeah.html | 2 +-
pelican/tests/output/custom/tags.html | 2 +-
pelican/tests/output/custom/this-is-a-super-article.html | 2 +-
pelican/tests/output/custom/unbelievable.html | 2 +-
pelican/tests/output/custom_locale/archives.html | 2 +-
.../tests/output/custom_locale/author/alexis-metaireau.html | 2 +-
.../tests/output/custom_locale/author/alexis-metaireau2.html | 2 +-
.../tests/output/custom_locale/author/alexis-metaireau3.html | 2 +-
pelican/tests/output/custom_locale/authors.html | 2 +-
pelican/tests/output/custom_locale/categories.html | 2 +-
pelican/tests/output/custom_locale/category/bar.html | 2 +-
pelican/tests/output/custom_locale/category/cat1.html | 2 +-
pelican/tests/output/custom_locale/category/misc.html | 2 +-
pelican/tests/output/custom_locale/category/yeah.html | 2 +-
.../custom_locale/drafts/a-draft-article-without-date.html | 2 +-
.../tests/output/custom_locale/drafts/a-draft-article.html | 2 +-
pelican/tests/output/custom_locale/index.html | 2 +-
pelican/tests/output/custom_locale/index2.html | 2 +-
pelican/tests/output/custom_locale/index3.html | 2 +-
pelican/tests/output/custom_locale/jinja2_template.html | 2 +-
pelican/tests/output/custom_locale/oh-yeah-fr.html | 2 +-
pelican/tests/output/custom_locale/override/index.html | 2 +-
.../custom_locale/pages/this-is-a-test-hidden-page.html | 2 +-
.../tests/output/custom_locale/pages/this-is-a-test-page.html | 2 +-
.../posts/2010/décembre/02/this-is-a-super-article/index.html | 2 +-
.../posts/2010/octobre/15/unbelievable/index.html | 2 +-
.../custom_locale/posts/2010/octobre/20/oh-yeah/index.html | 2 +-
.../posts/2011/avril/20/a-markdown-powered-article/index.html | 2 +-
.../custom_locale/posts/2011/février/17/article-1/index.html | 2 +-
.../custom_locale/posts/2011/février/17/article-2/index.html | 2 +-
.../custom_locale/posts/2011/février/17/article-3/index.html | 2 +-
.../posts/2012/février/29/second-article/index.html | 2 +-
.../2012/novembre/30/filename_metadata-example/index.html | 2 +-
pelican/tests/output/custom_locale/second-article-fr.html | 2 +-
pelican/tests/output/custom_locale/tag/bar.html | 2 +-
pelican/tests/output/custom_locale/tag/baz.html | 2 +-
pelican/tests/output/custom_locale/tag/foo.html | 2 +-
pelican/tests/output/custom_locale/tag/foobar.html | 2 +-
pelican/tests/output/custom_locale/tag/oh.html | 2 +-
pelican/tests/output/custom_locale/tag/yeah.html | 2 +-
pelican/tests/output/custom_locale/tags.html | 2 +-
pelican/themes/notmyidea/templates/github.html | 4 ++--
75 files changed, 76 insertions(+), 76 deletions(-)
diff --git a/pelican/tests/output/custom/a-markdown-powered-article.html b/pelican/tests/output/custom/a-markdown-powered-article.html
index 1cee58f6..b8359a6d 100644
--- a/pelican/tests/output/custom/a-markdown-powered-article.html
+++ b/pelican/tests/output/custom/a-markdown-powered-article.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/archives.html b/pelican/tests/output/custom/archives.html
index 5ca032d3..234fa63a 100644
--- a/pelican/tests/output/custom/archives.html
+++ b/pelican/tests/output/custom/archives.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/article-1.html b/pelican/tests/output/custom/article-1.html
index b8bc8e1d..4b670b16 100644
--- a/pelican/tests/output/custom/article-1.html
+++ b/pelican/tests/output/custom/article-1.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/article-2.html b/pelican/tests/output/custom/article-2.html
index 93403466..ad1e20fb 100644
--- a/pelican/tests/output/custom/article-2.html
+++ b/pelican/tests/output/custom/article-2.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/article-3.html b/pelican/tests/output/custom/article-3.html
index cdf52bd7..7157c014 100644
--- a/pelican/tests/output/custom/article-3.html
+++ b/pelican/tests/output/custom/article-3.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/author/alexis-metaireau.html b/pelican/tests/output/custom/author/alexis-metaireau.html
index 75bcb182..b4230aad 100644
--- a/pelican/tests/output/custom/author/alexis-metaireau.html
+++ b/pelican/tests/output/custom/author/alexis-metaireau.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/author/alexis-metaireau2.html b/pelican/tests/output/custom/author/alexis-metaireau2.html
index 1bf6f7c9..43823162 100644
--- a/pelican/tests/output/custom/author/alexis-metaireau2.html
+++ b/pelican/tests/output/custom/author/alexis-metaireau2.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/author/alexis-metaireau3.html b/pelican/tests/output/custom/author/alexis-metaireau3.html
index 082c3bc7..cf7a6031 100644
--- a/pelican/tests/output/custom/author/alexis-metaireau3.html
+++ b/pelican/tests/output/custom/author/alexis-metaireau3.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/authors.html b/pelican/tests/output/custom/authors.html
index 9b3b76cf..5ba9af8c 100644
--- a/pelican/tests/output/custom/authors.html
+++ b/pelican/tests/output/custom/authors.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/categories.html b/pelican/tests/output/custom/categories.html
index eab567e0..2c055fac 100644
--- a/pelican/tests/output/custom/categories.html
+++ b/pelican/tests/output/custom/categories.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/category/bar.html b/pelican/tests/output/custom/category/bar.html
index 02a4602f..7415f9f4 100644
--- a/pelican/tests/output/custom/category/bar.html
+++ b/pelican/tests/output/custom/category/bar.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/category/cat1.html b/pelican/tests/output/custom/category/cat1.html
index c7abc1a9..f72f8bc8 100644
--- a/pelican/tests/output/custom/category/cat1.html
+++ b/pelican/tests/output/custom/category/cat1.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/category/misc.html b/pelican/tests/output/custom/category/misc.html
index 303e35ad..895f253e 100644
--- a/pelican/tests/output/custom/category/misc.html
+++ b/pelican/tests/output/custom/category/misc.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/category/yeah.html b/pelican/tests/output/custom/category/yeah.html
index f69b5705..a6d76ac2 100644
--- a/pelican/tests/output/custom/category/yeah.html
+++ b/pelican/tests/output/custom/category/yeah.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/drafts/a-draft-article-without-date.html b/pelican/tests/output/custom/drafts/a-draft-article-without-date.html
index 786e0ae6..70879483 100644
--- a/pelican/tests/output/custom/drafts/a-draft-article-without-date.html
+++ b/pelican/tests/output/custom/drafts/a-draft-article-without-date.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/drafts/a-draft-article.html b/pelican/tests/output/custom/drafts/a-draft-article.html
index 508e2d43..8e56ba96 100644
--- a/pelican/tests/output/custom/drafts/a-draft-article.html
+++ b/pelican/tests/output/custom/drafts/a-draft-article.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/filename_metadata-example.html b/pelican/tests/output/custom/filename_metadata-example.html
index 9eff8f14..00b1f158 100644
--- a/pelican/tests/output/custom/filename_metadata-example.html
+++ b/pelican/tests/output/custom/filename_metadata-example.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/index.html b/pelican/tests/output/custom/index.html
index b5cf7189..b29d8d86 100644
--- a/pelican/tests/output/custom/index.html
+++ b/pelican/tests/output/custom/index.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/index2.html b/pelican/tests/output/custom/index2.html
index 3964bcb9..a1c3f5b5 100644
--- a/pelican/tests/output/custom/index2.html
+++ b/pelican/tests/output/custom/index2.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/index3.html b/pelican/tests/output/custom/index3.html
index 4abea6bb..93e0d029 100644
--- a/pelican/tests/output/custom/index3.html
+++ b/pelican/tests/output/custom/index3.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/jinja2_template.html b/pelican/tests/output/custom/jinja2_template.html
index 91506822..e745d4cf 100644
--- a/pelican/tests/output/custom/jinja2_template.html
+++ b/pelican/tests/output/custom/jinja2_template.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/oh-yeah-fr.html b/pelican/tests/output/custom/oh-yeah-fr.html
index caf2fdc8..8659bd0e 100644
--- a/pelican/tests/output/custom/oh-yeah-fr.html
+++ b/pelican/tests/output/custom/oh-yeah-fr.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom/oh-yeah.html b/pelican/tests/output/custom/oh-yeah.html
index 9e15a338..0825e211 100644
--- a/pelican/tests/output/custom/oh-yeah.html
+++ b/pelican/tests/output/custom/oh-yeah.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom/override/index.html b/pelican/tests/output/custom/override/index.html
index b7a58516..8a5df3b4 100644
--- a/pelican/tests/output/custom/override/index.html
+++ b/pelican/tests/output/custom/override/index.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/pages/this-is-a-test-hidden-page.html b/pelican/tests/output/custom/pages/this-is-a-test-hidden-page.html
index cd127354..df4e9090 100644
--- a/pelican/tests/output/custom/pages/this-is-a-test-hidden-page.html
+++ b/pelican/tests/output/custom/pages/this-is-a-test-hidden-page.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/pages/this-is-a-test-page.html b/pelican/tests/output/custom/pages/this-is-a-test-page.html
index 67666441..f9d959a5 100644
--- a/pelican/tests/output/custom/pages/this-is-a-test-page.html
+++ b/pelican/tests/output/custom/pages/this-is-a-test-page.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/second-article-fr.html b/pelican/tests/output/custom/second-article-fr.html
index 9a2ce96c..c53cc23e 100644
--- a/pelican/tests/output/custom/second-article-fr.html
+++ b/pelican/tests/output/custom/second-article-fr.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom/second-article.html b/pelican/tests/output/custom/second-article.html
index 4ddfe299..f42dd642 100644
--- a/pelican/tests/output/custom/second-article.html
+++ b/pelican/tests/output/custom/second-article.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom/tag/bar.html b/pelican/tests/output/custom/tag/bar.html
index 8c56761d..3abbc833 100644
--- a/pelican/tests/output/custom/tag/bar.html
+++ b/pelican/tests/output/custom/tag/bar.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/tag/baz.html b/pelican/tests/output/custom/tag/baz.html
index 4c7dbf4f..e2dfada4 100644
--- a/pelican/tests/output/custom/tag/baz.html
+++ b/pelican/tests/output/custom/tag/baz.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/tag/foo.html b/pelican/tests/output/custom/tag/foo.html
index 8fbf6d4d..c03bca5c 100644
--- a/pelican/tests/output/custom/tag/foo.html
+++ b/pelican/tests/output/custom/tag/foo.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/tag/foobar.html b/pelican/tests/output/custom/tag/foobar.html
index be73227f..d3609714 100644
--- a/pelican/tests/output/custom/tag/foobar.html
+++ b/pelican/tests/output/custom/tag/foobar.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/tag/oh.html b/pelican/tests/output/custom/tag/oh.html
index d9fbdb20..5530d037 100644
--- a/pelican/tests/output/custom/tag/oh.html
+++ b/pelican/tests/output/custom/tag/oh.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/tag/yeah.html b/pelican/tests/output/custom/tag/yeah.html
index 5dfa0d67..d0457390 100644
--- a/pelican/tests/output/custom/tag/yeah.html
+++ b/pelican/tests/output/custom/tag/yeah.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/tags.html b/pelican/tests/output/custom/tags.html
index 231901b8..e5b3b08f 100644
--- a/pelican/tests/output/custom/tags.html
+++ b/pelican/tests/output/custom/tags.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom/this-is-a-super-article.html b/pelican/tests/output/custom/this-is-a-super-article.html
index 2dac8f11..222fcbab 100644
--- a/pelican/tests/output/custom/this-is-a-super-article.html
+++ b/pelican/tests/output/custom/this-is-a-super-article.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom/unbelievable.html b/pelican/tests/output/custom/unbelievable.html
index d777df9e..0d88db61 100644
--- a/pelican/tests/output/custom/unbelievable.html
+++ b/pelican/tests/output/custom/unbelievable.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/archives.html b/pelican/tests/output/custom_locale/archives.html
index c3f25eb7..3e85bc13 100644
--- a/pelican/tests/output/custom_locale/archives.html
+++ b/pelican/tests/output/custom_locale/archives.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/author/alexis-metaireau.html b/pelican/tests/output/custom_locale/author/alexis-metaireau.html
index db0a7b2f..7582d623 100644
--- a/pelican/tests/output/custom_locale/author/alexis-metaireau.html
+++ b/pelican/tests/output/custom_locale/author/alexis-metaireau.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/author/alexis-metaireau2.html b/pelican/tests/output/custom_locale/author/alexis-metaireau2.html
index 0f1908c4..0ba022b7 100644
--- a/pelican/tests/output/custom_locale/author/alexis-metaireau2.html
+++ b/pelican/tests/output/custom_locale/author/alexis-metaireau2.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/author/alexis-metaireau3.html b/pelican/tests/output/custom_locale/author/alexis-metaireau3.html
index a5942573..5033e7f2 100644
--- a/pelican/tests/output/custom_locale/author/alexis-metaireau3.html
+++ b/pelican/tests/output/custom_locale/author/alexis-metaireau3.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/authors.html b/pelican/tests/output/custom_locale/authors.html
index 14a3e1ca..1d1bb320 100644
--- a/pelican/tests/output/custom_locale/authors.html
+++ b/pelican/tests/output/custom_locale/authors.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/categories.html b/pelican/tests/output/custom_locale/categories.html
index 8fb45c4e..9a684dd2 100644
--- a/pelican/tests/output/custom_locale/categories.html
+++ b/pelican/tests/output/custom_locale/categories.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/category/bar.html b/pelican/tests/output/custom_locale/category/bar.html
index 6915f22e..c061c8d8 100644
--- a/pelican/tests/output/custom_locale/category/bar.html
+++ b/pelican/tests/output/custom_locale/category/bar.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/category/cat1.html b/pelican/tests/output/custom_locale/category/cat1.html
index 5cf93f15..a1b9156b 100644
--- a/pelican/tests/output/custom_locale/category/cat1.html
+++ b/pelican/tests/output/custom_locale/category/cat1.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/category/misc.html b/pelican/tests/output/custom_locale/category/misc.html
index 2d2fbfc2..8df30965 100644
--- a/pelican/tests/output/custom_locale/category/misc.html
+++ b/pelican/tests/output/custom_locale/category/misc.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/category/yeah.html b/pelican/tests/output/custom_locale/category/yeah.html
index bab572c4..9e22f4f3 100644
--- a/pelican/tests/output/custom_locale/category/yeah.html
+++ b/pelican/tests/output/custom_locale/category/yeah.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/drafts/a-draft-article-without-date.html b/pelican/tests/output/custom_locale/drafts/a-draft-article-without-date.html
index dae74c58..cf8c8760 100644
--- a/pelican/tests/output/custom_locale/drafts/a-draft-article-without-date.html
+++ b/pelican/tests/output/custom_locale/drafts/a-draft-article-without-date.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/drafts/a-draft-article.html b/pelican/tests/output/custom_locale/drafts/a-draft-article.html
index ad8688d4..56f9e0b4 100644
--- a/pelican/tests/output/custom_locale/drafts/a-draft-article.html
+++ b/pelican/tests/output/custom_locale/drafts/a-draft-article.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/index.html b/pelican/tests/output/custom_locale/index.html
index 0499f5d5..5c5c3c27 100644
--- a/pelican/tests/output/custom_locale/index.html
+++ b/pelican/tests/output/custom_locale/index.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/index2.html b/pelican/tests/output/custom_locale/index2.html
index 35e1aca6..68d4f195 100644
--- a/pelican/tests/output/custom_locale/index2.html
+++ b/pelican/tests/output/custom_locale/index2.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/index3.html b/pelican/tests/output/custom_locale/index3.html
index 5b5c3a67..030ea072 100644
--- a/pelican/tests/output/custom_locale/index3.html
+++ b/pelican/tests/output/custom_locale/index3.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/jinja2_template.html b/pelican/tests/output/custom_locale/jinja2_template.html
index 75602f5e..3d2ac0e1 100644
--- a/pelican/tests/output/custom_locale/jinja2_template.html
+++ b/pelican/tests/output/custom_locale/jinja2_template.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/oh-yeah-fr.html b/pelican/tests/output/custom_locale/oh-yeah-fr.html
index baec35fa..a3203152 100644
--- a/pelican/tests/output/custom_locale/oh-yeah-fr.html
+++ b/pelican/tests/output/custom_locale/oh-yeah-fr.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/override/index.html b/pelican/tests/output/custom_locale/override/index.html
index 285e553b..f457679f 100644
--- a/pelican/tests/output/custom_locale/override/index.html
+++ b/pelican/tests/output/custom_locale/override/index.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/pages/this-is-a-test-hidden-page.html b/pelican/tests/output/custom_locale/pages/this-is-a-test-hidden-page.html
index 431d6849..12cab620 100644
--- a/pelican/tests/output/custom_locale/pages/this-is-a-test-hidden-page.html
+++ b/pelican/tests/output/custom_locale/pages/this-is-a-test-hidden-page.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/pages/this-is-a-test-page.html b/pelican/tests/output/custom_locale/pages/this-is-a-test-page.html
index 62af11b3..e945a3ed 100644
--- a/pelican/tests/output/custom_locale/pages/this-is-a-test-page.html
+++ b/pelican/tests/output/custom_locale/pages/this-is-a-test-page.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2010/décembre/02/this-is-a-super-article/index.html b/pelican/tests/output/custom_locale/posts/2010/décembre/02/this-is-a-super-article/index.html
index 1585c0db..336a13cf 100644
--- a/pelican/tests/output/custom_locale/posts/2010/décembre/02/this-is-a-super-article/index.html
+++ b/pelican/tests/output/custom_locale/posts/2010/décembre/02/this-is-a-super-article/index.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2010/octobre/15/unbelievable/index.html b/pelican/tests/output/custom_locale/posts/2010/octobre/15/unbelievable/index.html
index 3a9a3f5e..a5788171 100644
--- a/pelican/tests/output/custom_locale/posts/2010/octobre/15/unbelievable/index.html
+++ b/pelican/tests/output/custom_locale/posts/2010/octobre/15/unbelievable/index.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2010/octobre/20/oh-yeah/index.html b/pelican/tests/output/custom_locale/posts/2010/octobre/20/oh-yeah/index.html
index e39b8b68..23c57785 100644
--- a/pelican/tests/output/custom_locale/posts/2010/octobre/20/oh-yeah/index.html
+++ b/pelican/tests/output/custom_locale/posts/2010/octobre/20/oh-yeah/index.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2011/avril/20/a-markdown-powered-article/index.html b/pelican/tests/output/custom_locale/posts/2011/avril/20/a-markdown-powered-article/index.html
index 5f675a3d..c2e1cc57 100644
--- a/pelican/tests/output/custom_locale/posts/2011/avril/20/a-markdown-powered-article/index.html
+++ b/pelican/tests/output/custom_locale/posts/2011/avril/20/a-markdown-powered-article/index.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2011/février/17/article-1/index.html b/pelican/tests/output/custom_locale/posts/2011/février/17/article-1/index.html
index 05dc2de6..0742bc52 100644
--- a/pelican/tests/output/custom_locale/posts/2011/février/17/article-1/index.html
+++ b/pelican/tests/output/custom_locale/posts/2011/février/17/article-1/index.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2011/février/17/article-2/index.html b/pelican/tests/output/custom_locale/posts/2011/février/17/article-2/index.html
index 40d59bb2..a5201ffb 100644
--- a/pelican/tests/output/custom_locale/posts/2011/février/17/article-2/index.html
+++ b/pelican/tests/output/custom_locale/posts/2011/février/17/article-2/index.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2011/février/17/article-3/index.html b/pelican/tests/output/custom_locale/posts/2011/février/17/article-3/index.html
index bec205f8..fe175d6f 100644
--- a/pelican/tests/output/custom_locale/posts/2011/février/17/article-3/index.html
+++ b/pelican/tests/output/custom_locale/posts/2011/février/17/article-3/index.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2012/février/29/second-article/index.html b/pelican/tests/output/custom_locale/posts/2012/février/29/second-article/index.html
index 0f1a40c2..d2d3cfe1 100644
--- a/pelican/tests/output/custom_locale/posts/2012/février/29/second-article/index.html
+++ b/pelican/tests/output/custom_locale/posts/2012/février/29/second-article/index.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/posts/2012/novembre/30/filename_metadata-example/index.html b/pelican/tests/output/custom_locale/posts/2012/novembre/30/filename_metadata-example/index.html
index 6f200a7b..a596dbed 100644
--- a/pelican/tests/output/custom_locale/posts/2012/novembre/30/filename_metadata-example/index.html
+++ b/pelican/tests/output/custom_locale/posts/2012/novembre/30/filename_metadata-example/index.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/second-article-fr.html b/pelican/tests/output/custom_locale/second-article-fr.html
index 704b5d52..e631a575 100644
--- a/pelican/tests/output/custom_locale/second-article-fr.html
+++ b/pelican/tests/output/custom_locale/second-article-fr.html
@@ -15,7 +15,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/tag/bar.html b/pelican/tests/output/custom_locale/tag/bar.html
index 96142e9c..f8edf2f2 100644
--- a/pelican/tests/output/custom_locale/tag/bar.html
+++ b/pelican/tests/output/custom_locale/tag/bar.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/tag/baz.html b/pelican/tests/output/custom_locale/tag/baz.html
index e43246e3..ad8fefa9 100644
--- a/pelican/tests/output/custom_locale/tag/baz.html
+++ b/pelican/tests/output/custom_locale/tag/baz.html
@@ -13,7 +13,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/tag/foo.html b/pelican/tests/output/custom_locale/tag/foo.html
index e80d2340..688666f8 100644
--- a/pelican/tests/output/custom_locale/tag/foo.html
+++ b/pelican/tests/output/custom_locale/tag/foo.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/tag/foobar.html b/pelican/tests/output/custom_locale/tag/foobar.html
index a1169a88..6abc2d24 100644
--- a/pelican/tests/output/custom_locale/tag/foobar.html
+++ b/pelican/tests/output/custom_locale/tag/foobar.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/tag/oh.html b/pelican/tests/output/custom_locale/tag/oh.html
index 07c2542f..72cde941 100644
--- a/pelican/tests/output/custom_locale/tag/oh.html
+++ b/pelican/tests/output/custom_locale/tag/oh.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/tag/yeah.html b/pelican/tests/output/custom_locale/tag/yeah.html
index dabcaf7d..b0a1a5ac 100644
--- a/pelican/tests/output/custom_locale/tag/yeah.html
+++ b/pelican/tests/output/custom_locale/tag/yeah.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/tests/output/custom_locale/tags.html b/pelican/tests/output/custom_locale/tags.html
index 2ac682b4..40daf2ef 100644
--- a/pelican/tests/output/custom_locale/tags.html
+++ b/pelican/tests/output/custom_locale/tags.html
@@ -12,7 +12,7 @@
-
+
diff --git a/pelican/themes/notmyidea/templates/github.html b/pelican/themes/notmyidea/templates/github.html
index 75876edd..8e256af7 100644
--- a/pelican/themes/notmyidea/templates/github.html
+++ b/pelican/themes/notmyidea/templates/github.html
@@ -1,9 +1,9 @@
{% if GITHUB_URL %}
{% if GITHUB_POSITION != "left" %}
-
+
{% else %}
-
+
{% endif %}
{% endif %}
From 6a501917283c664c3724b1b8b46a96d4f1874d30 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 25 Jun 2024 10:49:07 +0200
Subject: [PATCH 27/52] Tweak Markdown-not-installed console warnings
Adding single-quotation marks should cause 'markdown' to be highlighted
in green, presumably via Rich.
---
pelican/readers.py | 4 ++--
pelican/tests/test_pelican.py | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/pelican/readers.py b/pelican/readers.py
index ee7e3466..3d0e8d58 100644
--- a/pelican/readers.py
+++ b/pelican/readers.py
@@ -353,8 +353,8 @@ class MarkdownReader(BaseReader):
def disabled_message(self) -> str:
return (
- "Could not import markdown.Markdown. "
- "Have you installed the markdown package?"
+ "Could not import 'markdown.Markdown'. "
+ "Have you installed the 'markdown' package?"
)
diff --git a/pelican/tests/test_pelican.py b/pelican/tests/test_pelican.py
index e243be61..a43afa3e 100644
--- a/pelican/tests/test_pelican.py
+++ b/pelican/tests/test_pelican.py
@@ -322,6 +322,6 @@ class TestPelican(LoggedTestCase):
self.assertLogCountEqual(
1,
".*article_with_md_extension.md: "
- "Could not import markdown.Markdown. "
- "Have you installed the markdown package?",
+ "Could not import 'markdown.Markdown'. "
+ "Have you installed the 'markdown' package?",
)
From bdd4e45628c901cad3c95f281c28d52a2bb676b4 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 25 Jun 2024 10:54:24 +0200
Subject: [PATCH 28/52] Enforce 75% code coverage in CI via Tox
---
tasks.py | 2 +-
tox.ini | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/tasks.py b/tasks.py
index 3a1722eb..cf9851ed 100644
--- a/tasks.py
+++ b/tasks.py
@@ -49,7 +49,7 @@ def coverage(c):
"""Generate code coverage of running the test suite."""
c.run(
f"{VENV_BIN}/pytest --cov=pelican --cov-report term-missing "
- "--cov-fail-under 74",
+ "--cov-fail-under 75",
pty=PTY,
)
c.run(f"{VENV_BIN}/coverage html", pty=PTY)
diff --git a/tox.ini b/tox.ini
index 61e8908a..7b8598ac 100644
--- a/tox.ini
+++ b/tox.ini
@@ -15,7 +15,7 @@ deps =
commands =
{envpython} --version
- pytest -s --cov=pelican pelican
+ pytest -s --cov=pelican --cov-fail-under 75 pelican
[testenv:docs]
basepython = python3.11
From 28e54106f2fc3f6c837cef62f2498fd75ae7e91e Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 25 Jun 2024 11:00:41 +0200
Subject: [PATCH 29/52] Update Ruff linter
---
.pre-commit-config.yaml | 2 +-
pyproject.toml | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index bfdd6149..9ae674ab 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -16,7 +16,7 @@ repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# ruff version should match the one in pyproject.toml
- rev: v0.4.6
+ rev: v0.4.10
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
diff --git a/pyproject.toml b/pyproject.toml
index dd256a44..1a2e1474 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -97,7 +97,7 @@ dev = [
"tox>=4.11.3",
"invoke>=2.2.0",
# ruff version should match the one in .pre-commit-config.yaml
- "ruff==0.4.6",
+ "ruff==0.4.10",
"tomli>=2.0.1; python_version < \"3.11\"",
]
From 36ebe91af78823860e4dc6c790f3f28507457016 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 25 Jun 2024 11:33:28 +0200
Subject: [PATCH 30/52] Rename default branch to `main`
---
.github/workflows/main.yml | 2 +-
CONTRIBUTING.rst | 4 ++--
README.rst | 4 ++--
docs/settings.rst | 2 +-
docs/themes.rst | 4 ++--
docs/tips.rst | 16 ++++++++--------
pelican/settings.py | 2 +-
7 files changed, 17 insertions(+), 17 deletions(-)
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 4c0127df..e07caa72 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -110,7 +110,7 @@ jobs:
environment: Deployment
needs: [test, lint, docs, build]
runs-on: ubuntu-latest
- if: github.ref=='refs/heads/master' && github.event_name!='pull_request' && github.repository == 'getpelican/pelican'
+ if: github.ref=='refs/heads/main' && github.event_name!='pull_request' && github.repository == 'getpelican/pelican'
permissions:
contents: write
diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst
index 4faace91..5ac5f0ad 100644
--- a/CONTRIBUTING.rst
+++ b/CONTRIBUTING.rst
@@ -24,7 +24,7 @@ Before you ask for help, please make sure you do the following:
3. Try reproducing the issue in a clean environment, ensuring you are using:
-* latest Pelican release (or an up-to-date Git clone of Pelican master)
+* latest Pelican release (or an up-to-date Git clone of Pelican ``main`` branch)
* latest releases of libraries used by Pelican
* no plugins or only those related to the issue
@@ -87,7 +87,7 @@ Using Git and GitHub
--------------------
* `Create a new branch`_ specific to your change (as opposed to making
- your commits in the master branch).
+ your commits in the ``main`` branch).
* **Don't put multiple unrelated fixes/features in the same branch / pull request.**
For example, if you're working on a new feature and find a bugfix that
doesn't *require* your new feature, **make a new distinct branch and pull
diff --git a/README.rst b/README.rst
index 3f708242..0e3577ec 100644
--- a/README.rst
+++ b/README.rst
@@ -64,8 +64,8 @@ Why the name “Pelican”?
.. _`Pelican's internals`: https://docs.getpelican.com/en/latest/internals.html
.. _`hosted on GitHub`: https://github.com/getpelican/pelican
-.. |build-status| image:: https://img.shields.io/github/actions/workflow/status/getpelican/pelican/main.yml?branch=master
- :target: https://github.com/getpelican/pelican/actions/workflows/main.yml?query=branch%3Amaster
+.. |build-status| image:: https://img.shields.io/github/actions/workflow/status/getpelican/pelican/main.yml?branch=main
+ :target: https://github.com/getpelican/pelican/actions/workflows/main.yml?query=branch%3Amain
:alt: GitHub Actions CI: continuous integration status
.. |pypi-version| image:: https://img.shields.io/pypi/v/pelican.svg
:target: https://pypi.org/project/pelican/
diff --git a/docs/settings.rst b/docs/settings.rst
index 4ae608c6..7269c0bd 100644
--- a/docs/settings.rst
+++ b/docs/settings.rst
@@ -28,7 +28,7 @@ Environment variables can also be used here but must be escaped appropriately::
Settings are configured in the form of a Python module (a file). There is an
`example settings file
-`_
+`_
available for reference.
To see a list of current settings in your environment, including both default
diff --git a/docs/themes.rst b/docs/themes.rst
index 2e01ec8e..ace5dcb9 100644
--- a/docs/themes.rst
+++ b/docs/themes.rst
@@ -17,7 +17,7 @@ To generate its HTML output, Pelican uses the `Jinja
`_ templating engine due to its flexibility and
straightforward syntax. If you want to create your own theme, feel free to take
inspiration from the `"simple" theme
-`_.
+`_.
To generate your site using a theme you have created (or downloaded manually
and then modified), you can specify that theme via the ``-t`` flag::
@@ -368,7 +368,7 @@ period_num A tuple of the form (``year``, ``month``, ``day``),
You can see an example of how to use `period` in the `"simple" theme
period_archives.html template
-`_.
+`_.
.. _period_archives_variable:
diff --git a/docs/tips.rst b/docs/tips.rst
index 1398ccd9..e5574c7c 100644
--- a/docs/tips.rst
+++ b/docs/tips.rst
@@ -89,18 +89,18 @@ Publishing a User Site to GitHub Pages from a Branch
----------------------------------------------------
To publish a Pelican site in the form of User Pages, you need to *push* the
-content of the ``output`` dir generated by Pelican to the ``master`` branch of
+content of the ``output`` dir generated by Pelican to the ``main`` branch of
your ``.github.io`` repository on GitHub.
Again, you can take advantage of ``ghp-import``::
$ pelican content -o output -s pelicanconf.py
$ ghp-import output -b gh-pages
- $ git push git@github.com:elemoine/elemoine.github.io.git gh-pages:master
+ $ git push git@github.com:elemoine/elemoine.github.io.git gh-pages:main
The ``git push`` command pushes the local ``gh-pages`` branch (freshly updated
by the ``ghp-import`` command) to the ``elemoine.github.io`` repository's
-``master`` branch on GitHub.
+``main`` branch on GitHub.
.. note::
@@ -116,10 +116,10 @@ inside the ``Pelican`` folder you can run::
$ pelican content -o .. -s pelicanconf.py
-Now you can push the whole project ``.github.io`` to the master
+Now you can push the whole project ``.github.io`` to the main
branch of your GitHub repository::
- $ git push origin master
+ $ git push origin main
(assuming origin is set to your remote repository).
@@ -127,7 +127,7 @@ Publishing to GitHub Pages Using a Custom GitHub Actions Workflow
-----------------------------------------------------------------
Pelican-powered sites can be published to GitHub Pages via a `custom workflow
-`_.
+`_.
To use it:
1. Enable GitHub Pages in your repo: go to **Settings → Pages** and choose
@@ -144,7 +144,7 @@ To use it:
workflow_dispatch:
jobs:
deploy:
- uses: "getpelican/pelican/.github/workflows/github_pages.yml@master"
+ uses: "getpelican/pelican/.github/workflows/github_pages.yml@main"
permissions:
contents: "read"
pages: "write"
@@ -152,7 +152,7 @@ To use it:
with:
settings: "publishconf.py"
- You may want to replace the ``@master`` with the ID of a specific commit in
+ You may want to replace the ``@main`` with the ID of a specific commit in
this repo in order to pin the version of the reusable workflow that you're using:
``uses: getpelican/pelican/.github/workflows/github_pages.yml@``.
If you do this you might want to get Dependabot to send you automated pull
diff --git a/pelican/settings.py b/pelican/settings.py
index 46b761a5..66d6beeb 100644
--- a/pelican/settings.py
+++ b/pelican/settings.py
@@ -347,7 +347,7 @@ def handle_deprecated_settings(settings: Settings) -> Settings:
"FILES_TO_COPY",
"STATIC_PATHS and EXTRA_PATH_METADATA",
"https://github.com/getpelican/pelican/"
- "blob/master/docs/settings.rst#path-metadata",
+ "blob/main/docs/settings.rst#path-metadata",
),
]:
if old in settings:
From 513abbfdc668946590194c637dbe90ec228aaf6f Mon Sep 17 00:00:00 2001
From: Agathe
Date: Tue, 25 Jun 2024 15:07:41 +0200
Subject: [PATCH 31/52] Introduce paragraph count summary (#2761)
Co-authored-by: Justin Mayer
---
docs/content.rst | 5 ++++-
docs/settings.rst | 8 ++++++++
pelican/contents.py | 8 +++++++-
pelican/tests/test_contents.py | 25 +++++++++++++++++++++++++
pelican/tests/test_utils.py | 17 +++++++++++++++++
pelican/utils.py | 19 +++++++++++++++++++
6 files changed, 80 insertions(+), 2 deletions(-)
diff --git a/docs/content.rst b/docs/content.rst
index 4277b838..7d7e2cfa 100644
--- a/docs/content.rst
+++ b/docs/content.rst
@@ -162,7 +162,10 @@ author you can use ``author`` field.
If you do not explicitly specify summary metadata for a given post, the
``SUMMARY_MAX_LENGTH`` setting can be used to specify how many words from the
-beginning of an article are used as the summary.
+beginning of an article are used as the summary. You can also use an article's
+first N paragraphs as its summary using the ``SUMMARY_MAX_PARAGRAPHS`` setting.
+If both settings are in use, the specified number of paragraphs will
+be used but may be truncated to respect the specified maximum length.
You can also extract any metadata from the filename through a regular
expression to be set in the ``FILENAME_METADATA`` setting. All named groups
diff --git a/docs/settings.rst b/docs/settings.rst
index 7269c0bd..93c632d2 100644
--- a/docs/settings.rst
+++ b/docs/settings.rst
@@ -308,6 +308,14 @@ Basic settings
does not otherwise specify a summary. Setting to ``None`` will cause the
summary to be a copy of the original content.
+.. data:: SUMMARY_MAX_PARAGRAPHS = None
+
+ When creating a short summary of an article, this will be the number of
+ paragraphs to use as the summary. This only applies if your content
+ does not otherwise specify a summary. Setting to ``None`` will cause the
+ summary to use the whole text (up to ``SUMMARY_MAX_LENGTH``) instead of just
+ the first N paragraphs.
+
.. data:: SUMMARY_END_SUFFIX = '…'
When creating a short summary of an article and the result was truncated to
diff --git a/pelican/contents.py b/pelican/contents.py
index cf13dabc..5a403261 100644
--- a/pelican/contents.py
+++ b/pelican/contents.py
@@ -28,6 +28,7 @@ from pelican.utils import (
sanitised_join,
set_date_tzinfo,
slugify,
+ truncate_html_paragraphs,
truncate_html_words,
)
@@ -440,8 +441,13 @@ class Content:
if "summary" in self.metadata:
return self.metadata["summary"]
+ content = self.content
+ max_paragraphs = self.settings.get("SUMMARY_MAX_PARAGRAPHS")
+ if max_paragraphs is not None:
+ content = truncate_html_paragraphs(self.content, max_paragraphs)
+
if self.settings["SUMMARY_MAX_LENGTH"] is None:
- return self.content
+ return content
return truncate_html_words(
self.content,
diff --git a/pelican/tests/test_contents.py b/pelican/tests/test_contents.py
index 81f8907c..06d1a690 100644
--- a/pelican/tests/test_contents.py
+++ b/pelican/tests/test_contents.py
@@ -116,6 +116,31 @@ class TestPage(TestBase):
page = Page(**page_kwargs)
self.assertEqual(page.summary, "")
+ def test_summary_paragraph(self):
+ # If SUMMARY_MAX_PARAGRAPHS is set, the generated summary should
+ # not exceed the given paragraph count.
+ page_kwargs = self._copy_page_kwargs()
+ settings = get_settings()
+ page_kwargs["settings"] = settings
+ del page_kwargs["metadata"]["summary"]
+ settings["SUMMARY_MAX_PARAGRAPHS"] = 1
+ settings["SUMMARY_MAX_LENGTH"] = None
+ page = Page(**page_kwargs)
+ self.assertEqual(page.summary, TEST_CONTENT)
+
+ def test_summary_paragraph_max_length(self):
+ # If both SUMMARY_MAX_PARAGRAPHS and SUMMARY_MAX_LENGTH are set,
+ # the generated summary should not exceed the given paragraph count and
+ # not exceed the given length.
+ page_kwargs = self._copy_page_kwargs()
+ settings = get_settings()
+ page_kwargs["settings"] = settings
+ del page_kwargs["metadata"]["summary"]
+ settings["SUMMARY_MAX_PARAGRAPHS"] = 1
+ settings["SUMMARY_MAX_LENGTH"] = 10
+ page = Page(**page_kwargs)
+ self.assertEqual(page.summary, truncate_html_words(TEST_CONTENT, 10))
+
def test_summary_end_suffix(self):
# If a :SUMMARY_END_SUFFIX: is set, and there is no other summary,
# generated summary should contain the specified marker at the end.
diff --git a/pelican/tests/test_utils.py b/pelican/tests/test_utils.py
index 0da59dd4..c35b756c 100644
--- a/pelican/tests/test_utils.py
+++ b/pelican/tests/test_utils.py
@@ -401,6 +401,23 @@ class TestUtils(LoggedTestCase):
self.assertEqual(utils.truncate_html_words("Ӓ text", 20), "Ӓ text")
self.assertEqual(utils.truncate_html_words("઼ text", 20), "઼ text")
+ def test_truncate_html_paragraphs(self):
+ one = "one
"
+
+ self.assertEqual(utils.truncate_html_paragraphs(one, 0), "")
+ self.assertEqual(utils.truncate_html_paragraphs(one, 1), one)
+ self.assertEqual(utils.truncate_html_paragraphs(one, 2), one)
+
+ two = one + "two
"
+ self.assertEqual(utils.truncate_html_paragraphs(two, 1), one)
+ self.assertEqual(utils.truncate_html_paragraphs(two, 2), two)
+
+ three = two + "three
"
+ self.assertEqual(utils.truncate_html_paragraphs(three, 1), one)
+ self.assertEqual(utils.truncate_html_paragraphs(three, 2), two)
+ self.assertEqual(utils.truncate_html_paragraphs(three, 3), three)
+ self.assertEqual(utils.truncate_html_paragraphs(three, 4), three)
+
def test_process_translations(self):
fr_articles = []
en_articles = []
diff --git a/pelican/utils.py b/pelican/utils.py
index b780ab97..69d9dde5 100644
--- a/pelican/utils.py
+++ b/pelican/utils.py
@@ -631,6 +631,25 @@ def truncate_html_words(s: str, num: int, end_text: str = "…") -> str:
return out
+def truncate_html_paragraphs(s, count):
+ """Truncate HTML to a certain number of paragraphs.
+
+ :param count: number of paragraphs to keep
+
+ Newlines in the HTML are preserved.
+ """
+ paragraphs = []
+ tag_stop = 0
+ substr = s[:]
+ for _ in range(count):
+ substr = substr[tag_stop:]
+ tag_start = substr.find("")
+ tag_stop = substr.find("
") + len("
")
+ paragraphs.append(substr[tag_start:tag_stop])
+
+ return "".join(paragraphs)
+
+
def process_translations(
content_list: list[Content],
translation_id: str | Collection[str] | None = None,
From d85f493ee377ae2040bbcd45ce752d9c53e598a9 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 30 Jul 2024 09:56:27 +0200
Subject: [PATCH 32/52] Add initial configuration for Vale prose linter
Vale:
---
.gitignore | 1 +
.vale.ini | 10 ++++++++++
2 files changed, 11 insertions(+)
create mode 100644 .vale.ini
diff --git a/.gitignore b/.gitignore
index 65e4d759..a3d27ca8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -17,6 +17,7 @@ samples/output
*.pem
*.lock
.pdm-python
+.vale
.venv
# direnv
diff --git a/.vale.ini b/.vale.ini
new file mode 100644
index 00000000..aad18229
--- /dev/null
+++ b/.vale.ini
@@ -0,0 +1,10 @@
+StylesPath = .vale/styles
+
+Vocab = Pelican
+
+MinAlertLevel = suggestion
+
+Packages = proselint, alex
+
+[*]
+BasedOnStyles = Vale, proselint, alex
From bb0ed26fdd3c1bbfbca6f384a01a304fab954a00 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Tue, 30 Jul 2024 10:00:36 +0200
Subject: [PATCH 33/52] Document how to have same source & output hierarchy
---
docs/faq.rst | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/docs/faq.rst b/docs/faq.rst
index cecc1157..bbf058cd 100644
--- a/docs/faq.rst
+++ b/docs/faq.rst
@@ -99,6 +99,15 @@ If you want to include metadata in templates outside the article context (e.g.,
{% if article and article.modified %}
+How do I make my output folder structure identical to my content hierarchy?
+===========================================================================
+
+Try these settings::
+
+ USE_FOLDER_AS_CATEGORY = False
+ PATH_METADATA = "(?P.*)\..*"
+ ARTICLE_URL = ARTICLE_SAVE_AS = PAGE_URL = PAGE_SAVE_AS = "{path_no_ext}.html"
+
How do I assign custom templates on a per-page basis?
=====================================================
From 2d375bc135f15403137a6322568a2e572aff3831 Mon Sep 17 00:00:00 2001
From: Agathe Porte <989521+gagath@users.noreply.github.com>
Date: Sun, 4 Aug 2024 22:39:50 +0900
Subject: [PATCH 34/52] tasks.py.jinja2: optimize imports
When opening the generated tasks.py file with a Python linter enabled,
some imports will be marked as unecessary depending on the options
passed to pelican-quickstart.
Add if statements around the optional imports so they are used
only when necessary.
---
pelican/tools/templates/tasks.py.jinja2 | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/pelican/tools/templates/tasks.py.jinja2 b/pelican/tools/templates/tasks.py.jinja2
index 1a0f02d1..26af6f0d 100644
--- a/pelican/tools/templates/tasks.py.jinja2
+++ b/pelican/tools/templates/tasks.py.jinja2
@@ -2,11 +2,15 @@ import os
import shlex
import shutil
import sys
+{% if github %}
import datetime
+{% endif %}
from invoke import task
from invoke.main import program
+{% if cloudfiles %}
from invoke.util import cd
+{% endif %}
from pelican import main as pelican_main
from pelican.server import ComplexHTTPRequestHandler, RootedHTTPServer
from pelican.settings import DEFAULT_CONFIG, get_settings_from_file
From 4201256a5bb154db647dcc9871c9a774ea797e71 Mon Sep 17 00:00:00 2001
From: GiovanH
Date: Thu, 12 Sep 2024 06:28:51 -0500
Subject: [PATCH 35/52] Add disabled status for #3304 (#3305)
---
docs/content.rst | 9 ++++++++-
pelican/contents.py | 24 ++++++++++++++++++++++--
pelican/generators.py | 15 ++++++++++++++-
pelican/readers.py | 5 ++++-
pelican/tests/content/article_skip.md | 5 +++++
pelican/tests/test_cache.py | 5 +++--
6 files changed, 56 insertions(+), 7 deletions(-)
create mode 100644 pelican/tests/content/article_skip.md
diff --git a/docs/content.rst b/docs/content.rst
index 7d7e2cfa..6c58aa11 100644
--- a/docs/content.rst
+++ b/docs/content.rst
@@ -89,7 +89,7 @@ contains a list of reserved metadata keywords:
``summary`` Brief description of content for index pages
``lang`` Content language ID (``en``, ``fr``, etc.)
``translation`` If content is a translation of another (``true`` or ``false``)
-``status`` Content status: ``draft``, ``hidden``, or ``published``
+``status`` Content status: ``draft``, ``hidden``, ``skip``, or ``published``
``template`` Name of template to use to generate content (without extension)
``save_as`` Save content to this relative file path
``url`` URL to use for this article/page
@@ -633,6 +633,13 @@ attribute. Hidden posts will be output to ``ARTICLE_SAVE_AS`` as expected, but
are not included by default in tag, category, and author indexes, nor in the
main article feed. This has the effect of creating an "unlisted" post.
+Skip Posts
+==========
+
+Posts marked with ``skip`` status are ignored entirely. They are not processed
+nor output to the ``ARTICLE_SAVE_AS`` path. Such posts will similarly not be
+included in indexes or feeds.
+
.. _W3C ISO 8601: https://www.w3.org/TR/NOTE-datetime
.. _AsciiDoc: https://asciidoc.org
.. _Pelican Plugins: https://github.com/pelican-plugins
diff --git a/pelican/contents.py b/pelican/contents.py
index 5a403261..0769f875 100644
--- a/pelican/contents.py
+++ b/pelican/contents.py
@@ -547,9 +547,29 @@ class Content:
self._summary = self.metadata["summary"]
+class SkipStub(Content):
+ """Stub class representing content that should not be processed in any way."""
+
+ def __init__(
+ self, content, metadata=None, settings=None, source_path=None, context=None
+ ):
+ self.source_path = source_path
+
+ def is_valid(self):
+ return False
+
+ @property
+ def content(self):
+ raise NotImplementedError("Stub content should not be read")
+
+ @property
+ def save_as(self):
+ raise NotImplementedError("Stub content cannot be saved")
+
+
class Page(Content):
mandatory_properties = ("title",)
- allowed_statuses = ("published", "hidden", "draft")
+ allowed_statuses = ("published", "hidden", "draft", "skip")
default_status = "published"
default_template = "page"
@@ -560,7 +580,7 @@ class Page(Content):
class Article(Content):
mandatory_properties = ("title", "date", "category")
- allowed_statuses = ("published", "hidden", "draft")
+ allowed_statuses = ("published", "hidden", "draft", "skip")
default_status = "published"
default_template = "article"
diff --git a/pelican/generators.py b/pelican/generators.py
index 548c494f..6b44d79e 100644
--- a/pelican/generators.py
+++ b/pelican/generators.py
@@ -19,7 +19,7 @@ from jinja2 import (
)
from pelican.cache import FileStampDataCacher
-from pelican.contents import Article, Page, Static
+from pelican.contents import Article, Page, SkipStub, Static
from pelican.plugins import signals
from pelican.plugins._utils import plugin_enabled
from pelican.readers import Readers
@@ -690,6 +690,10 @@ class ArticlesGenerator(CachingGenerator):
self._add_failed_source_path(f)
continue
+ if isinstance(article, SkipStub):
+ logger.debug("Safely skipping %s", f)
+ continue
+
if not article.is_valid():
self._add_failed_source_path(f)
continue
@@ -702,6 +706,8 @@ class ArticlesGenerator(CachingGenerator):
all_drafts.append(article)
elif article.status == "hidden":
hidden_articles.append(article)
+ elif article.status == "skip":
+ raise AssertionError("Documents with 'skip' status should be skipped")
self.add_source_path(article)
self.add_static_links(article)
@@ -899,6 +905,10 @@ class PagesGenerator(CachingGenerator):
self._add_failed_source_path(f)
continue
+ if isinstance(page, SkipStub):
+ logger.debug("Safely skipping %s", f)
+ continue
+
if not page.is_valid():
self._add_failed_source_path(f)
continue
@@ -911,6 +921,9 @@ class PagesGenerator(CachingGenerator):
hidden_pages.append(page)
elif page.status == "draft":
draft_pages.append(page)
+ elif page.status == "skip":
+ raise AssertionError("Documents with 'skip' status should be skipped")
+
self.add_source_path(page)
self.add_static_links(page)
diff --git a/pelican/readers.py b/pelican/readers.py
index 3d0e8d58..59aa7ca3 100644
--- a/pelican/readers.py
+++ b/pelican/readers.py
@@ -15,7 +15,7 @@ from docutils.writers.html4css1 import HTMLTranslator, Writer
from pelican import rstdirectives # NOQA
from pelican.cache import FileStampDataCacher
-from pelican.contents import Author, Category, Page, Tag
+from pelican.contents import Author, Category, Page, SkipStub, Tag
from pelican.plugins import signals
from pelican.utils import file_suffix, get_date, pelican_open, posixize_path
@@ -669,6 +669,9 @@ class Readers(FileStampDataCacher):
)
context_signal.send(context_sender, metadata=metadata)
+ if metadata.get("status") == "skip":
+ content_class = SkipStub
+
return content_class(
content=content,
metadata=metadata,
diff --git a/pelican/tests/content/article_skip.md b/pelican/tests/content/article_skip.md
new file mode 100644
index 00000000..02cd5a52
--- /dev/null
+++ b/pelican/tests/content/article_skip.md
@@ -0,0 +1,5 @@
+Title: Skipped article
+Date: 2024-06-30
+Status: skip
+
+This content will not be rendered.
diff --git a/pelican/tests/test_cache.py b/pelican/tests/test_cache.py
index a1bbc559..8876a8a5 100644
--- a/pelican/tests/test_cache.py
+++ b/pelican/tests/test_cache.py
@@ -183,15 +183,16 @@ class TestCache(unittest.TestCase):
generator.readers.read_file = MagicMock()
generator.generate_context()
"""
- 6 files don't get cached because they were not valid
+ 7 files don't get cached because they were not valid
- article_with_attributes_containing_double_quotes.html
- article_with_comments.html
- article_with_null_attributes.html
- 2012-11-30_md_w_filename_meta#foo-bar.md
- empty.md
- empty_with_bom.md
+ - article_skip.md
"""
- self.assertEqual(generator.readers.read_file.call_count, 6)
+ self.assertEqual(generator.readers.read_file.call_count, 7)
def test_article_reader_content_caching(self):
"""Test raw article content caching at the reader level"""
From 5687883d4b813c2bb95baa1a9c8d2c7cecfa4160 Mon Sep 17 00:00:00 2001
From: Egbert <10352354+egberts@users.noreply.github.com>
Date: Thu, 12 Sep 2024 07:21:12 -0500
Subject: [PATCH 36/52] Bump Pygments to 2.16.1 in test requirements; fixes
#3385 (#3386)
---
requirements/test.pip | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/requirements/test.pip b/requirements/test.pip
index 8eb1029f..a2c35d57 100644
--- a/requirements/test.pip
+++ b/requirements/test.pip
@@ -1,11 +1,11 @@
# Tests
-Pygments==2.14.0
+Pygments>=2.16.1
pytest
pytest-cov
pytest-xdist[psutil]
# Optional Packages
-Markdown==3.5.1
+Markdown>=3.5.1
BeautifulSoup4
lxml
typogrify
From e609b4d78a4ada21bacff7a5977cfcac68e5cab3 Mon Sep 17 00:00:00 2001
From: GeorgeHu <43069137+GeorgeHu6@users.noreply.github.com>
Date: Sun, 15 Sep 2024 20:29:01 +0800
Subject: [PATCH 37/52] Translate documentation into Simplified Chinese (#3346)
---
docs/conf.py | 3 +
docs/locale/zh_CN/LC_MESSAGES/changelog.po | 1669 +++++++++++++++
docs/locale/zh_CN/LC_MESSAGES/content.po | 1074 ++++++++++
docs/locale/zh_CN/LC_MESSAGES/contribute.po | 731 +++++++
docs/locale/zh_CN/LC_MESSAGES/faq.po | 457 +++++
docs/locale/zh_CN/LC_MESSAGES/importer.po | 321 +++
docs/locale/zh_CN/LC_MESSAGES/index.po | 134 ++
docs/locale/zh_CN/LC_MESSAGES/install.po | 244 +++
docs/locale/zh_CN/LC_MESSAGES/internals.po | 172 ++
.../zh_CN/LC_MESSAGES/pelican-themes.po | 206 ++
docs/locale/zh_CN/LC_MESSAGES/plugins.po | 711 +++++++
docs/locale/zh_CN/LC_MESSAGES/publish.po | 329 +++
docs/locale/zh_CN/LC_MESSAGES/quickstart.po | 151 ++
docs/locale/zh_CN/LC_MESSAGES/report.po | 249 +++
docs/locale/zh_CN/LC_MESSAGES/settings.po | 1815 +++++++++++++++++
docs/locale/zh_CN/LC_MESSAGES/sphinx.po | 60 +
docs/locale/zh_CN/LC_MESSAGES/themes.po | 1269 ++++++++++++
docs/locale/zh_CN/LC_MESSAGES/tips.po | 679 ++++++
18 files changed, 10274 insertions(+)
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/changelog.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/content.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/contribute.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/faq.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/importer.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/index.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/install.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/internals.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/pelican-themes.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/plugins.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/publish.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/quickstart.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/report.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/settings.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/sphinx.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/themes.po
create mode 100644 docs/locale/zh_CN/LC_MESSAGES/tips.po
diff --git a/docs/conf.py b/docs/conf.py
index b812ee4c..2cac97e3 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -19,6 +19,9 @@ with open("../pyproject.toml", "rb") as f:
# -- General configuration ----------------------------------------------------
templates_path = ["_templates"]
+locale_dirs = ["locale/"]
+gettext_compact = False
+gettext_uuid = True
extensions = [
"sphinx.ext.autodoc",
"sphinx.ext.extlinks",
diff --git a/docs/locale/zh_CN/LC_MESSAGES/changelog.po b/docs/locale/zh_CN/LC_MESSAGES/changelog.po
new file mode 100644
index 00000000..18fec089
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/changelog.po
@@ -0,0 +1,1669 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../changelog.rst:2 4aeac72dd31d4f34ae17a35dc3dfb6bb
+msgid "Release history"
+msgstr "更新日志"
+
+#: ../../changelog.rst:5 1e1473d7633a41f6bf9b31bdd8b7fe79
+msgid "4.9.1 - 2023-11-15"
+msgstr ""
+
+#: ../../changelog.rst:7 b8408b62a2644333a6f79c46ed50ae40
+msgid "Ensure ``tzdata`` dependency is installed on Windows"
+msgstr ""
+
+#: ../../changelog.rst:10 fd27b54d8bc441ffaad0eed5342e3fb0
+msgid "4.9.0 - 2023-11-12"
+msgstr ""
+
+#: ../../changelog.rst:12 d2a96d9c7641406db9b5bbbf1e1591f1
+msgid "Upgrade code to new minimum supported Python version: 3.8"
+msgstr ""
+
+#: ../../changelog.rst:13 eecb4e70e6d64882a298a68a906aa7e7
+msgid ""
+"Settings support for ``pathlib.Path`` `(#2758) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:14 73d4ff7624894557974d1e14072e995e
+msgid ""
+"Various improvements to Simple theme (`#2976 "
+"`_ & `#3234 "
+"`_)"
+msgstr ""
+
+#: ../../changelog.rst:15 242c2330a6264406a9444beb84da5682
+msgid ""
+"Use Furo as Sphinx documentation theme `(#3023) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:16 dabb5eb48294457aba25a322ab1d0197
+msgid ""
+"Default to 100 articles maximum in feeds `(#3127) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:17 86ddf69ef3e74a5e9633b231762624d3
+msgid ""
+"Add ``period_archives common context`` variable `(#3148) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:18 2e0c631a1cf04880b862de6b807eff48
+msgid ""
+"Use ``watchfiles`` as the file-watching backend `(#3151) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:19 59ca5ac64d244f93abcda99d3544de2a
+msgid ""
+"Add GitHub Actions workflow for GitHub Pages `(#3189) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:20 88ed863544e64ea5a09301d25cd80d3e
+msgid ""
+"Allow dataclasses in settings `(#3204) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:21 b101d1a2f7c04acfa220a77ccf85dc35
+msgid ""
+"Switch build tool to PDM instead of Setuptools/Poetry `(#3220) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:22 422f54c14c4144b986362c831b56cb86
+msgid ""
+"Provide a ``plugin_enabled`` Jinja test for themes `(#3235) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:23 1a85c8e28699430cb4ee54e6b1cda9ba
+msgid ""
+"Preserve connection order in Blinker `(#3238) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:24 f605f3f56552418d80225548b3bea74c
+msgid ""
+"Remove social icons from default ``notmyidea`` theme `(#3240) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:25 de509b7854fe41f986b7ea8c86034ded
+msgid ""
+"Remove unreliable ``WRITE_SELECTED`` feature `(#3243) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:26 1206eb9fb5c344c0ae2fa5ae405bb29e
+msgid ""
+"Importer: Report broken embedded video links when importing from Tumblr "
+"`(#3177) `_"
+msgstr ""
+
+#: ../../changelog.rst:27 eeefe71248724cd8928500b64c1d24f0
+msgid ""
+"Importer: Remove newline addition when iterating Photo post types "
+"`(#3178) `_"
+msgstr ""
+
+#: ../../changelog.rst:28 d9bbceb0175b42b9be8b19b89546c7fd
+msgid ""
+"Importer: Force timestamp conversion in Tumblr importer to be UTC with "
+"offset `(#3221) `_"
+msgstr ""
+
+#: ../../changelog.rst:29 fcb7a001e25345bda01cc0d7fbdcc0c1
+msgid ""
+"Importer: Use tempfile for intermediate HTML file for Pandoc `(#3221) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:30 c7a0a3a319754ada970b27f9913833bd
+msgid ""
+"Switch linters to Ruff `(#3223) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:33 b80948b635ca4ba3bdaf0efedf9e8230
+msgid "4.8.0 - 2022-07-11"
+msgstr ""
+
+#: ../../changelog.rst:35 c95dd083acb34ccea579bed98c19d95b
+msgid ""
+"Use JSON values for extra settings in Invoke tasks template `(#2994) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:36 54acbf33444345efa17b6006650cfff2
+msgid ""
+"Add content tag for links, which can help with things like Twitter social"
+" cards `(#3001) `_"
+msgstr ""
+
+#: ../../changelog.rst:37 28a4102c014741ac987ba8be6ff00565
+msgid ""
+"Improve word count behavior when generating summary `(#3002) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:40 00956e307c3647078780260ec470f0c4
+msgid "4.7.2 - 2022-02-09"
+msgstr ""
+
+#: ../../changelog.rst:42 9782bf3d611b4168b76fe33602f13d26
+msgid ""
+"Fix incorrect parsing of parameters specified via `-e` / `--extra-"
+"settings` option flags `(#2938) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:43 b3ce4b03bd92409ea6aea120cd2d3a4f
+msgid ""
+"Add ``categories.html`` template to default theme `(#2973) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:44 bdcd1255d2534a5c992a53c2c9640299
+msgid ""
+"Document how to use plugins to inject content `(#2922) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:47 9052d76f02fc4509998872f8c650696d
+msgid "4.7.1 - 2021-10-12"
+msgstr ""
+
+#: ../../changelog.rst:49 1ddc283dca434367a9eebebb4dc19c55
+msgid ""
+"Extend rich logging to server component `(#2927) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:50 2ebe1d316cc541eba3ef3d20512c97f0
+msgid ""
+"Fix an issue where metadata flagged to be discarded was being cached "
+"`(#2926) `_"
+msgstr ""
+
+#: ../../changelog.rst:51 7561e4a903db49bba3c7cb5d22ea25be
+msgid ""
+"Adjust suffix in server to allow redirection when needed `(#2931) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:52 369516860be2437b9099796b0b3c7847
+msgid ""
+"Add MIME types for web fonts `(#2929) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:53 2a4dd51d3c2d46c1a0a774274436fc74
+msgid ""
+"Distribute sample data used to run tests `(#2935) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:54 63a08ba90a054e369d1be50c491f094b
+msgid "Add Python 3.10 to test matrix"
+msgstr ""
+
+#: ../../changelog.rst:57 f07f93ca41894e2ea7de889e68dddd63
+msgid "4.7.0 - 2021-10-01"
+msgstr ""
+
+#: ../../changelog.rst:59 1e0f42b1b76e4eb4a356612459563660
+msgid ""
+"Improve default theme rendering on mobile and other small screen devices "
+"`(#2914) `_"
+msgstr ""
+
+#: ../../changelog.rst:60 2ae6e8430fd4421994f330f095111d0e
+msgid ""
+"Add support for hidden articles `(#2866) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:61 eabcc4a0ac764f3991805d2f746cd415
+msgid ""
+"Improve word count behavior when generating summary CJK & other locales "
+"`(#2864) `_"
+msgstr ""
+
+#: ../../changelog.rst:62 9a1b80fe805a4c35960c6cba82d813b2
+msgid ""
+"Add progress spinner during generation `(#2869) "
+"`_ and richer logging "
+"`(#2897) `_, both via "
+"`Rich `_"
+msgstr ""
+
+#: ../../changelog.rst:64 5ea56ecd1a0740a1bc75e6f60515dfa8
+msgid ""
+"Invoke tasks ``serve`` and ``livereload`` now auto-open a web browser "
+"pointing to the locally-served web site `(#2764) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:65 60ed0fd02107499ead142c41c827f71a
+msgid ""
+"Support some date format codes used by ISO dates `(#2902) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:66 fbf7c4ded7af44a6813c0b26432d6905
+msgid ""
+"Document how to add a new writer `(#2901) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:69 fbada9e3ad0845b4a72f9688cf251a6a
+msgid "4.6.0 - 2021-03-23"
+msgstr ""
+
+#: ../../changelog.rst:71 fb814688de1a4df58087cb466d7fa24f
+msgid ""
+"Add new URL pattern to ``PAGINATION_PATTERNS`` for the last page in the "
+"list `(#1401) `_"
+msgstr ""
+
+#: ../../changelog.rst:72 9c5ae9de4b3f4ee7bb54ba0f5fe9194b
+msgid ""
+"Speed up ``livereload`` Invoke task via caching `(#2847) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:73 ccfa403160e6435990a51f311c059f65
+msgid ""
+"Ignore ``None`` return value from ``get_generators`` signal `(#2850) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:74 e00f58f952cf473390d2d3a0bff95f26
+msgid "Relax dependency minimum versions and remove upper bounds"
+msgstr ""
+
+#: ../../changelog.rst:77 7d2fd1353eda4e5cb27a27dae71fda0c
+msgid "4.5.4 - 2021-01-04"
+msgstr ""
+
+#: ../../changelog.rst:79 d40e6e0035144705b52124f970bc3ea3
+msgid ""
+"Replace plugin definitions in settings with string representations after "
+"registering, so they can be cached correctly `(#2828) "
+"`_."
+msgstr ""
+
+#: ../../changelog.rst:82 13f1634fef1f4a65a64ad54159de14fe
+msgid "4.5.3 - 2020-12-01"
+msgstr ""
+
+#: ../../changelog.rst:84 19753217e0b04230998d9f5c9730a423
+msgid "Fix a mistake made in PR #2821"
+msgstr ""
+
+#: ../../changelog.rst:87 1c8a0889b5de47178fab5b9d5d085c55
+msgid "4.5.2 - 2020-11-22"
+msgstr ""
+
+#: ../../changelog.rst:89 8c30ac8608f54fd48f29f1e48f640ccd
+msgid "Improve logging of generators and writer loaders"
+msgstr ""
+
+#: ../../changelog.rst:92 2673cef2ee1c42bdad7f7a80c77002c6
+msgid "4.5.1 - 2020-11-02"
+msgstr ""
+
+#: ../../changelog.rst:94 50a7b8039d1d45b4bf85550da4c40318
+msgid ""
+"Refactor intra-site link discovery in order to match more permissively "
+"`(#2646) `_"
+msgstr ""
+
+#: ../../changelog.rst:95 009addb3893a4c9b98af8eba13e57e11
+msgid ""
+"Fix plugins running twice in auto-reload mode `(#2817) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:96 43f7f7e70f3948cdaaa3fb6b7a6ab45d
+msgid ""
+"Add notice to use ``from pelican import signals`` instead of ``import "
+"pelican.signals`` `(#2805) "
+"`_"
+msgstr ""
+
+#: ../../changelog.rst:99 ef2a1b597d854881bf89d6240fe59ee0
+msgid "4.5.0 - 2020-08-20"
+msgstr ""
+
+#: ../../changelog.rst:101 d6f141fa55fc43cfa36eac89d4ec4a67
+msgid "Add namespace plugin support; list plugins via ``pelican-plugins`` command"
+msgstr ""
+
+#: ../../changelog.rst:102 83d9116dd10b404fb3d978977a91f03a
+msgid "Override settings via ``-e`` / ``--extra-settings`` CLI option flags"
+msgstr ""
+
+#: ../../changelog.rst:103 772c3e4941e64bc9a5a41ee644e980b3
+msgid "Add settings for custom Jinja globals and tests"
+msgstr ""
+
+#: ../../changelog.rst:104 cf2bd72795894ce796ae65a26307fa9e
+msgid "Customize article summary ellipsis via ``SUMMARY_END_SUFFIX`` setting"
+msgstr ""
+
+#: ../../changelog.rst:105 3494ccef87de4029a51d34e9f6ebac8c
+msgid "Customize Typogrify dash handling via new ``TYPOGRIFY_DASHES`` setting"
+msgstr ""
+
+#: ../../changelog.rst:106 441907e7fc27419cad1f678c3d81fcdd
+msgid "Support Unicode when generating slugs"
+msgstr ""
+
+#: ../../changelog.rst:107 0466696922dd4904a9a061c79d9e5d01
+msgid "Support Asciidoc ``.adoc`` file generation in Pelican importer"
+msgstr ""
+
+#: ../../changelog.rst:108 0711923af6544d84a09b027877cd7318
+msgid "Improve user experience when ``pelican --listen`` web server is quit"
+msgstr ""
+
+#: ../../changelog.rst:109 1736b73cd9354c5fb276263a0158f1d0
+msgid "Improve Invoke tasks template"
+msgstr ""
+
+#: ../../changelog.rst:110 a243c2afd72349ebb46076aef63a62af
+msgid "Include tests in source distributions"
+msgstr ""
+
+#: ../../changelog.rst:111 d3659b2430704e179785f6edeea9d975
+msgid "Switch CI from Travis to GitHub Actions"
+msgstr ""
+
+#: ../../changelog.rst:112 a9ee05a0579d4153935499a3f3bdcc47
+msgid "Remove support for Python 2.7"
+msgstr ""
+
+#: ../../changelog.rst:115 eb3830c633c14e63995b8fbcf8e3d29b
+msgid "4.2.0 - 2019-10-17"
+msgstr ""
+
+#: ../../changelog.rst:117 5af9b29432a94955813a11932e9e38c8
+msgid "Support inline SVGs; don't treat titles in SVGs as HTML titles"
+msgstr ""
+
+#: ../../changelog.rst:118 d776137d56d04320a1a70ced25696379
+msgid "Add category to feeds (in addition to tags)"
+msgstr ""
+
+#: ../../changelog.rst:119 ab3c5b4616544a3d89492ff849de5932
+msgid "Improve content metadata field docs"
+msgstr ""
+
+#: ../../changelog.rst:120 aa20a63221484e90954aaac555dba376
+msgid "Add docs for including other Markdown/reST files in content"
+msgstr ""
+
+#: ../../changelog.rst:123 f40de58367e94d50af3e6e700523edc7
+msgid "4.1.3 - 2019-10-09"
+msgstr ""
+
+#: ../../changelog.rst:125 910c8615c3224456a42555389c268e4c
+msgid "Fix quick-start docs regarding ``pelican --listen``"
+msgstr ""
+
+#: ../../changelog.rst:126 1c9961cd18bd4d17ae1f9ff0f3f45990
+msgid "Set default listen address to 127.0.0.1"
+msgstr ""
+
+#: ../../changelog.rst:127 7108f2b9c2d8444b8fa1ca32a26e36cc
+msgid "Add extra/optional Markdown dependency to setup.py"
+msgstr ""
+
+#: ../../changelog.rst:128 7d9eed3579384908b8ab564a4c358df8
+msgid "Use correct SSH port syntax for rsync in tasks.py"
+msgstr ""
+
+#: ../../changelog.rst:129 3b55feb812b14a1198b04659aa01ecf0
+msgid "Place all deprecated settings handling together"
+msgstr ""
+
+#: ../../changelog.rst:130 dc17ca3853c04536a3ade24a93d079ac
+msgid "Add related project URLs for display on PyPI"
+msgstr ""
+
+#: ../../changelog.rst:131 c513a9e1fed74fe3ae3c23ffe2f804d9
+msgid "Skip some tests on Windows that can't pass due to filesystem differences"
+msgstr ""
+
+#: ../../changelog.rst:134 ced29508dce44f0eb42c45aedc672fa6
+msgid "4.1.2 - 2019-09-23"
+msgstr ""
+
+#: ../../changelog.rst:136 c448cf2e59da43248819ddb51f9f9738
+msgid "Fix pelican.settings.load_source to avoid caching issues - PR #2621"
+msgstr ""
+
+#: ../../changelog.rst:139 98b3a78914f14383858960c37872cec0
+msgid "4.1.1 - 2019-08-23"
+msgstr ""
+
+#: ../../changelog.rst:141 7569ab6dfb9f4f59a4d9414a9ec307ac
+msgid "Add AutoPub to auto-publish releases on PR merge"
+msgstr ""
+
+#: ../../changelog.rst:142 29b086166a89485e9151534a891c8794
+msgid "Add CSS classes for reStructuredText figures"
+msgstr ""
+
+#: ../../changelog.rst:143 3d90d9a7e7f244aeb5ef4bc09624c9d8
+msgid "Pass ``argv`` to Pelican ``main`` entrypoint"
+msgstr ""
+
+#: ../../changelog.rst:144 33de38d2ec8641ca865cebb06167ec58
+msgid "Set default content status to a blank string rather than ``None``"
+msgstr ""
+
+#: ../../changelog.rst:147 9ba143abfcdf4a9a86f7866b897c9831
+msgid "4.1.0 - 2019-07-14"
+msgstr ""
+
+#: ../../changelog.rst:149 cc59d3e8f5f64f5a9ec02b56956e4d53
+msgid "Live browser reload upon changed files (provided via Invoke task)"
+msgstr ""
+
+#: ../../changelog.rst:150 1013f5e7df5448b5a808743127ed0740
+msgid "Add ``pyproject.toml``, managed by Poetry"
+msgstr ""
+
+#: ../../changelog.rst:151 9548fcd5133743259a8e586f69e6453e
+msgid "Support for invoking ``python -m pelican``"
+msgstr ""
+
+#: ../../changelog.rst:152 c1ca4a3bfa27477ebcfd9ac5757cd20b
+msgid "Add relative source path attribute to content"
+msgstr ""
+
+#: ../../changelog.rst:153 14c8367983884cd5913ef4aeaaae2ebe
+msgid "Allow directories in ``EXTRA_PATH_METADATA``"
+msgstr ""
+
+#: ../../changelog.rst:154 493069ecda9345cdab15204358d49856
+msgid ""
+"Add ``all_articles`` variable to period pages (for recent posts "
+"functionality)"
+msgstr ""
+
+#: ../../changelog.rst:155 57597a2f853047128a7f19d871a767cd
+msgid "Improve debug mode output"
+msgstr ""
+
+#: ../../changelog.rst:156 c1e2985b649844aface3795c16f24799
+msgid "Remove blank or duplicate summaries from Atom feed"
+msgstr ""
+
+#: ../../changelog.rst:157 be874126bdaa46ab868e9d5d572973ba
+msgid ""
+"Fix bugs in pagination, pelican-import, pelican-quickstart, and feed "
+"importer"
+msgstr ""
+
+#: ../../changelog.rst:160 3220150f83f64d869d28b2f8abdfae29
+msgid "4.0.1 (2018-11-30)"
+msgstr ""
+
+#: ../../changelog.rst:162 55ef92708e464069b85c860f407c44ee
+msgid "Refactor ``pelican.server`` logging"
+msgstr ""
+
+#: ../../changelog.rst:163 bbe751997c7541f78979d7885be777ad
+msgid "Fix bug in which all static files were processed as \"draft\""
+msgstr ""
+
+#: ../../changelog.rst:164 e85f8cfa33124937bff767d633c505e6
+msgid "Bug fixes for Invoke/Makefile automation, Importer, and other miscellanea"
+msgstr ""
+
+#: ../../changelog.rst:166 aee9e749eaa6417c9d7617678fbd5017
+#, python-format
+msgid ""
+"If upgrading from 3.7.x or earlier, please note that slug-related "
+"settings in 4.0+ use ``{slug}`` and/or ``{lang}`` rather than ``%s``. If "
+"``%s``-style settings are encountered, Pelican will emit a warning and "
+"fall back to the default setting. Some user-submitted themes might try to"
+" format setting values but fail upon site build with a ``TypeError``. In "
+"such cases, the theme needs to be updated. For example, instead of "
+"``TAG_FEED_ATOM|format(tag.slug)``, use "
+"``TAG_FEED_ATOM.format(slug=tag.slug)``"
+msgstr ""
+
+#: ../../changelog.rst:175 1c9f10c7ca554583840076dd4198471b
+msgid "4.0.0 (2018-11-13)"
+msgstr ""
+
+#: ../../changelog.rst:177 2e48c6a93f014447a24f76ec22c56634
+msgid "Replace ``develop_server.sh`` script with ``pelican --listen``"
+msgstr ""
+
+#: ../../changelog.rst:178 e9913592f867453ca8eb027547556190
+msgid "Improved copy/link behavior for large static files (e.g., videos)"
+msgstr ""
+
+#: ../../changelog.rst:179 7b739431500a4e508b4eddee2944998c
+msgid ""
+"New ``{static}`` syntax to link to static content; content linked to by "
+"``{static}`` and ``{attach}`` is automatically copied over even if not in"
+" ``STATIC_PATHS``"
+msgstr ""
+
+#: ../../changelog.rst:182 7d5ec1addb4a49b6825a365c1b28e6b7
+msgid "Pages can now have ``draft`` status"
+msgstr ""
+
+#: ../../changelog.rst:183 567c77a6a7c24d999b974ce0ed8ea7f9
+msgid "Show current settings via new ``--print-settings`` flag"
+msgstr ""
+
+#: ../../changelog.rst:184 f8206229f89f474990ad86f3670eb6c6
+#, python-format
+msgid ""
+"All settings for slugs now use ``{slug}`` and/or ``{lang}`` rather than "
+"``%s``. If ``%s``-style settings are encountered, Pelican will emit a "
+"warning and fallback to the default setting."
+msgstr ""
+
+#: ../../changelog.rst:187 55c29729d5ae42f6931b0af7ea314bcb
+msgid "New signals: ``feed_generated`` and ``page_generated_write_page``"
+msgstr ""
+
+#: ../../changelog.rst:188 fdd81adbccd2499988dda1b8faef1ab3
+msgid "Replace Fabric with Invoke and ``fabfile.py`` template with ``tasks.py``"
+msgstr ""
+
+#: ../../changelog.rst:189 85659c414dad4293b8a0d6ad9350c4d9
+msgid ""
+"Replace ``PAGINATED_DIRECT_TEMPLATES`` by ``PAGINATED_TEMPLATES``, "
+"extending control over pagination to all templates and making page size "
+"variable"
+msgstr ""
+
+#: ../../changelog.rst:191 2e76745f8fea417fb90052f755372212
+msgid ""
+"Replace ``SLUG_SUBSTITUTIONS`` (and friends) by "
+"``SLUG_REGEX_SUBSTITUTIONS`` for more finegrained control"
+msgstr ""
+
+#: ../../changelog.rst:193 c477dc73b63646c2bf339afff54a2e5f
+msgid ""
+"``'{base_name}'`` value in ``PAGINATION_PATTERNS`` setting no longer "
+"strips ``'bar'`` from ``'foo/bar.html'`` (unless ``'bar' == 'index'``)."
+msgstr ""
+
+#: ../../changelog.rst:195 0c9192b9f8c64af491d33f9358694940
+msgid ""
+"``ARTICLE_ORDER_BY`` and ``PAGE_ORDER_BY`` now also affect 1) category, "
+"tag and author pages 2) feeds 3) draft and hidden articles and pages"
+msgstr ""
+
+#: ../../changelog.rst:197 6e339043faff4d4a9a718a7571bf9698
+msgid ""
+"New ``ARTICLE_TRANSLATION_ID`` and ``PAGE_TRANSLATION_ID`` settings to "
+"specify metadata attributes used to identify/disable translations"
+msgstr ""
+
+#: ../../changelog.rst:199 84e3cebb5adf4c45bda8f132772f2bdd
+msgid "Make the HTML reader parse multiple occurrences of metadata tags as a list"
+msgstr ""
+
+#: ../../changelog.rst:200 790b535916b4402e8f3e568a96d208cc
+msgid "New Blogger XML backup importer"
+msgstr ""
+
+#: ../../changelog.rst:201 84ba1adba13c4c66a843be015263cc5f
+msgid ""
+"Wordpress importer now updates file links to point to local copies if the"
+" files were downloaded with ``--wp-attach``."
+msgstr ""
+
+#: ../../changelog.rst:203 e40ac2db0d404e3d8b51e350256eb49b
+msgid ""
+"Importer no longer inserts extra newlines, to prevent breaking of HTML "
+"attributes."
+msgstr ""
+
+#: ../../changelog.rst:205 a026ba70157640f9afdbbfd1c52635ed
+msgid ""
+"Pelican server now prioritises ``foo.html`` and ``foo/index.html`` over "
+"``foo/`` when resolving ``foo``."
+msgstr ""
+
+#: ../../changelog.rst:209 7bd3c3fdc45a4e848499d05fd1a2149a
+msgid "3.7.1 (2017-01-10)"
+msgstr ""
+
+#: ../../changelog.rst:211 a2224771f8184ef2ae2ae19e69ffff95
+msgid "Fix locale issues in Quickstart script"
+msgstr ""
+
+#: ../../changelog.rst:212 4bc8c9d8dbf24260a84512695081a437
+msgid "Specify encoding for README and CHANGELOG in setup.py"
+msgstr ""
+
+#: ../../changelog.rst:215 cdc85601d26440c08ba36b90b241218a
+msgid "3.7.0 (2016-12-12)"
+msgstr ""
+
+#: ../../changelog.rst:217 88cad459481748c385a4d15e5041255c
+msgid "Atom feeds output ```` in addition to ````"
+msgstr ""
+
+#: ../../changelog.rst:218 e8f51cd31ea94d1cb0fff327607a5106
+msgid ""
+"Atom feeds use ```` for the original publication date and "
+"```` for modifications"
+msgstr ""
+
+#: ../../changelog.rst:220 56be71bb20124ccbb10bf502c2158ebd
+msgid "Simplify Atom feed ID generation and support URL fragments"
+msgstr ""
+
+#: ../../changelog.rst:221 1ece62b3d5424ec4abd099d5b2bf20e0
+msgid "Produce category feeds with category-specific titles"
+msgstr ""
+
+#: ../../changelog.rst:222 106c730749474695b90ef8e5ddd31a7e
+msgid ""
+"RSS feeds now default to summary instead of full content; set "
+"``RSS_FEED_SUMMARY_ONLY = False`` to revert to previous behavior"
+msgstr ""
+
+#: ../../changelog.rst:224 14f1280956dc466a97042a5a313f9511
+msgid "Replace ``MD_EXTENSIONS`` with ``MARKDOWN`` setting"
+msgstr ""
+
+#: ../../changelog.rst:225 57cec9a1574f40f691b026cd680b681e
+msgid ""
+"Replace ``JINJA_EXTENSIONS`` with more-robust ``JINJA_ENVIRONMENT`` "
+"setting"
+msgstr ""
+
+#: ../../changelog.rst:226 9a398118c3d34bb996dc9af2d9c9503a
+msgid ""
+"Improve summary truncation logic to handle special characters and tags "
+"that span multiple lines, using HTML parser instead of regular "
+"expressions"
+msgstr ""
+
+#: ../../changelog.rst:228 75ef90817db34f7ea869a68fcc3fb469
+msgid "Include summary when looking for intra-site link substitutions"
+msgstr ""
+
+#: ../../changelog.rst:229 264f880b25284b01b7135c2a2b9e8dc1
+msgid "Link to authors and index via ``{author}name`` and ``{index}`` syntax"
+msgstr ""
+
+#: ../../changelog.rst:230 4c7abfddef0b454882888ba479aea6b7
+msgid "Override widget names via ``LINKS_WIDGET_NAME`` and ``SOCIAL_WIDGET_NAME``"
+msgstr ""
+
+#: ../../changelog.rst:231 2c5e79d0ad6141c9b6a19ee3e65d091e
+msgid "Add ``INDEX_SAVE_AS`` option to override default ``index.html`` value"
+msgstr ""
+
+#: ../../changelog.rst:232 6f89cd4a39ec445297f7dbb93e662e45
+msgid "Remove ``PAGES`` context variable for themes in favor of ``pages``"
+msgstr ""
+
+#: ../../changelog.rst:233 5b5ca0f599de4532964b3abe99a8c0d7
+msgid ""
+"``SLUG_SUBSTITUTIONS`` now accepts 3-tuple elements, allowing URL slugs "
+"to contain non-alphanumeric characters"
+msgstr ""
+
+#: ../../changelog.rst:235 159f3122fe94405489ccc20fe78f53b5
+msgid ""
+"Tag and category slugs can be controlled with greater precision using the"
+" ``TAG_SUBSTITUTIONS`` and ``CATEGORY_SUBSTITUTIONS`` settings"
+msgstr ""
+
+#: ../../changelog.rst:237 e163a8d8d61a4997b4259fcad5005d9c
+msgid ""
+"Author slugs can be controlled with greater precision using the "
+"``AUTHOR_SUBSTITUTIONS`` setting"
+msgstr ""
+
+#: ../../changelog.rst:239 f81c1120fcd44bfc9dd76acfb090ca9c
+msgid "``DEFAULT_DATE`` can be defined as a string"
+msgstr ""
+
+#: ../../changelog.rst:240 d79a66c8b8b44b3a93ec70011feae3e4
+msgid "Use ``mtime`` instead of ``ctime`` when ``DEFAULT_DATE = 'fs'``"
+msgstr ""
+
+#: ../../changelog.rst:241 ec0aa5c74458441c9ba450673f5fd2ef
+msgid "Add ``--fatal=errors|warnings`` option for use with continuous integration"
+msgstr ""
+
+#: ../../changelog.rst:242 13b4ab828a2941dfa8f1418685bb81a0
+msgid ""
+"When using generator-level caching, ensure previously-cached files are "
+"processed instead of just new files."
+msgstr ""
+
+#: ../../changelog.rst:244 d89e5097e9984f3daf4db6e9b929ada0
+msgid "Add Python and Pelican version information to debug output"
+msgstr ""
+
+#: ../../changelog.rst:245 4716f79323444484a70f7fe8c2650e1f
+msgid "Improve compatibility with Python 3.5"
+msgstr ""
+
+#: ../../changelog.rst:246 0f44c8d133b84c41a41d850300da1578
+msgid "Comply with and enforce PEP8 guidelines"
+msgstr ""
+
+#: ../../changelog.rst:247 c334d1c279204190893641f5ac313e36
+msgid "Replace tables in settings documentation with ``data::`` directives"
+msgstr ""
+
+#: ../../changelog.rst:250 461f1d0f43544a69be1139a9f19fe25a
+msgid "3.6.3 (2015-08-14)"
+msgstr ""
+
+#: ../../changelog.rst:252 7cff2bfca67f43bcb81338e645c16d6a
+msgid "Fix permissions issue in release tarball"
+msgstr ""
+
+#: ../../changelog.rst:255 73ecf430824c4621a9feba3aeb0f0435
+msgid "3.6.2 (2015-08-01)"
+msgstr ""
+
+#: ../../changelog.rst:257 304aa2b89bdb4d6a9765f92c169eeab7
+msgid "Fix installation errors related to Unicode in tests"
+msgstr ""
+
+#: ../../changelog.rst:258 8b544b800b20492db937b02285e42065
+msgid "Don't show pagination in ``notmyidea`` theme if there's only one page"
+msgstr ""
+
+#: ../../changelog.rst:259 f4aa88761161465faaf260a5b8fd25a9
+msgid "Make hidden pages available in context"
+msgstr ""
+
+#: ../../changelog.rst:260 13a3a8e59edc4125afa6dee4ed568e9d
+msgid "Improve URLWrapper comparison"
+msgstr ""
+
+#: ../../changelog.rst:263 fa56610009e8407a89af312d093f2aff
+msgid "3.6.0 (2015-06-15)"
+msgstr ""
+
+#: ../../changelog.rst:265 c4f546492e6447edb4d87c9317bdfb3f
+msgid "Disable caching by default in order to prevent potential confusion"
+msgstr ""
+
+#: ../../changelog.rst:266 b874f6f5b4734a5c80587442728a7544
+msgid "Improve caching behavior, replacing ``pickle`` with ``cpickle``"
+msgstr ""
+
+#: ../../changelog.rst:267 1f5690a0d5b6437e99c0ea9104de979b
+msgid "Allow Markdown or reST content in metadata fields other than ``summary``"
+msgstr ""
+
+#: ../../changelog.rst:268 a1f397d14aca4c879211d95a5ca892db
+msgid "Support semicolon-separated author/tag lists"
+msgstr ""
+
+#: ../../changelog.rst:269 9926a6f073cc4fa9813df12d652898be
+msgid "Improve flexibility of article sorting"
+msgstr ""
+
+#: ../../changelog.rst:270 e832f800cde5424bb332cc49f30f3f0a
+msgid "Add ``--relative-urls`` argument"
+msgstr ""
+
+#: ../../changelog.rst:271 3d1c82c08deb4a778f807be5b779d381
+msgid "Support devserver listening on addresses other than localhost"
+msgstr ""
+
+#: ../../changelog.rst:272 b6ee74584c064fac80c6f0e37d4f1d68
+msgid "Unify HTTP server handlers to ``pelican.server`` throughout"
+msgstr ""
+
+#: ../../changelog.rst:273 7e5010e2d8b74a03b694e8fa433fdf98
+msgid "Handle intra-site links to draft posts"
+msgstr ""
+
+#: ../../changelog.rst:274 a9afa1c067be459886fd7998d52f59d3
+msgid "Move ``tag_cloud`` from core to plugin"
+msgstr ""
+
+#: ../../changelog.rst:275 432317300d7a4b2f82199c0f275716e4
+msgid "Load default theme's external resources via HTTPS"
+msgstr ""
+
+#: ../../changelog.rst:276 56de44e81ae14997afb15c15e59f36ce
+msgid "Import drafts from WordPress XML"
+msgstr ""
+
+#: ../../changelog.rst:277 f1ef4f1c13434d6b9614ebe9ebddfce6
+msgid "Improve support for Windows users"
+msgstr ""
+
+#: ../../changelog.rst:278 0fef1b4c413d491a98aba0c84e082594
+msgid "Enhance logging and test suite"
+msgstr ""
+
+#: ../../changelog.rst:279 432c66ec8584401797ea817ec661c45b
+msgid "Clean up and refactor codebase"
+msgstr ""
+
+#: ../../changelog.rst:280 e22e5fb2b5264d1ca6eb78c067c76a32
+msgid "New signals: ``all_generators_finalized`` and ``page_writer_finalized``"
+msgstr ""
+
+#: ../../changelog.rst:283 b4d02cf4a5b642dcbb0237738d79bfcb
+msgid "3.5.0 (2014-11-04)"
+msgstr ""
+
+#: ../../changelog.rst:285 e9efd7356dc9488aa6f4f20ba995683a
+msgid ""
+"Introduce ``ARTICLE_ORDER_BY`` and ``PAGE_ORDER_BY`` settings to control "
+"the order of articles and pages."
+msgstr ""
+
+#: ../../changelog.rst:287 7cba6f51788f47f391c2eb2c35bff315
+msgid "Include time zone information in dates rendered in templates."
+msgstr ""
+
+#: ../../changelog.rst:288 8288271ca2e74d6da347bdce53a3cf59
+msgid "Expose the reader name in the metadata for articles and pages."
+msgstr ""
+
+#: ../../changelog.rst:289 0c44eda91d9c4722b8ae87ed75416fd1
+msgid ""
+"Add the ability to store static files along with content in the same "
+"directory as articles and pages using ``{attach}`` in the path."
+msgstr ""
+
+#: ../../changelog.rst:291 d96ca5c3ced44a7db8997feda6d5c36d
+msgid ""
+"Prevent Pelican from raising an exception when there are duplicate pieces"
+" of metadata in a Markdown file."
+msgstr ""
+
+#: ../../changelog.rst:293 59a2c665716a4d51bdec967e877f86a1
+msgid ""
+"Introduce the ``TYPOGRIFY_IGNORE_TAGS`` setting to add HTML tags to be "
+"ignored by Typogrify."
+msgstr ""
+
+#: ../../changelog.rst:295 fa33c1b08c7b4286b25b56b4ea285c5a
+#, python-format
+msgid ""
+"Add the ability to use ``-`` in date formats to strip leading zeros. For "
+"example, ``%-d/%-m/%y`` will now result in the date ``9/8/12``."
+msgstr ""
+
+#: ../../changelog.rst:297 64d61ee9d8ae4414b9b84a8051cd5522
+msgid ""
+"Ensure feed generation is correctly disabled during quickstart "
+"configuration."
+msgstr ""
+
+#: ../../changelog.rst:298 85d7dfece0244142a1e486fbae2beb01
+msgid ""
+"Fix ``PAGE_EXCLUDES`` and ``ARTICLE_EXCLUDES`` from incorrectly matching "
+"sub-directories."
+msgstr ""
+
+#: ../../changelog.rst:300 3acc9c23e76e4b289d9de3705c416913
+msgid "Introduce ``STATIC_EXCLUDE`` setting to add static file excludes."
+msgstr ""
+
+#: ../../changelog.rst:301 10dd085e254948f986aa41f9bd5ba73b
+msgid ""
+"Fix an issue when using ``PAGINATION_PATTERNS`` while ``RELATIVE_URLS`` "
+"is enabled."
+msgstr ""
+
+#: ../../changelog.rst:303 f7b355566396425cbd08985d5771e6d4
+msgid ""
+"Fix feed generation causing links to use the wrong language for month "
+"names when using other locales."
+msgstr ""
+
+#: ../../changelog.rst:305 28f48794554048308015e2fb52cc4c5b
+msgid ""
+"Fix an issue where the authors list in the simple template wasn't "
+"correctly formatted."
+msgstr ""
+
+#: ../../changelog.rst:307 5509ab0c156845d1a7f1a59306ccfe6c
+msgid "Fix an issue when parsing non-string URLs from settings."
+msgstr ""
+
+#: ../../changelog.rst:308 4da2cbc439db416daeb4442a29645664
+msgid "Improve consistency of debug and warning messages."
+msgstr ""
+
+#: ../../changelog.rst:311 2e98c390cf6b4b4b93ddcce23014dbe9
+msgid "3.4.0 (2014-07-01)"
+msgstr ""
+
+#: ../../changelog.rst:313 b3f12ddd82d74409b734a8bd10458173
+msgid "Speed up content generation via new caching mechanism"
+msgstr ""
+
+#: ../../changelog.rst:314 c1772deca0344f74aad300e77e2641b2
+msgid "Add selective post generation (instead of always building entire site)"
+msgstr ""
+
+#: ../../changelog.rst:315 7db419405a1740ef917e19f05015228a
+msgid "Many documentation improvements, including switching to prettier RtD theme"
+msgstr ""
+
+#: ../../changelog.rst:316 a045ce18d5724b888849a2036fdf626d
+msgid "Add support for multiple content and plugin paths"
+msgstr ""
+
+#: ../../changelog.rst:317 75ddeed2af5e4a56a83e6b4026807ebf
+msgid ""
+"Add ``:modified:`` metadata field to complement ``:date:``. Used to "
+"specify the last date and time an article was updated independently from "
+"the date and time it was published."
+msgstr ""
+
+#: ../../changelog.rst:320 0049c916daed45a6bcd389ad0c120732
+msgid "Add support for multiple authors via new ``:authors:`` metadata field"
+msgstr ""
+
+#: ../../changelog.rst:321 bd572ae6cd4c4783b751a35f4f001ed6
+msgid "Watch for changes in static directories when in auto-regeneration mode"
+msgstr ""
+
+#: ../../changelog.rst:322 b48f6001e36e428491aa05fa2d419cd1
+msgid "Add filters to limit log output when desired"
+msgstr ""
+
+#: ../../changelog.rst:323 5d67072828f04eb1a2b8d37aca1706e4
+msgid "Add language support to drafts"
+msgstr ""
+
+#: ../../changelog.rst:324 5f6eef6c622a468ab0750bc4fbafffcd
+msgid "Add ``SLUGIFY_SOURCE`` setting to control how post slugs are generated"
+msgstr ""
+
+#: ../../changelog.rst:325 f77675fb2cb94589b821eaf0116d5b33
+msgid "Fix many issues relating to locale and encoding"
+msgstr ""
+
+#: ../../changelog.rst:326 b90206854315449696be45e4d459e5b4
+msgid "Apply Typogrify filter to post summary"
+msgstr ""
+
+#: ../../changelog.rst:327 86383b9bc16e4b4a9ec3d15e7b727ca1
+msgid ""
+"Preserve file metadata (e.g. time stamps) when copying static files to "
+"output"
+msgstr ""
+
+#: ../../changelog.rst:328 f844db2703af4069830a3fbcbd3841bd
+msgid "Move AsciiDoc support from Pelican core into separate plugin"
+msgstr ""
+
+#: ../../changelog.rst:329 1c30d68d58dc42d9b33c2662f1258bcd
+msgid ""
+"Produce inline links instead of reference-style links when importing "
+"content"
+msgstr ""
+
+#: ../../changelog.rst:330 fa8944dc8e284fe4bf78ad3a0676af3f
+msgid "Improve handling of ``IGNORE_FILES`` setting behavior"
+msgstr ""
+
+#: ../../changelog.rst:331 f4c5805f6879483f9aa25e247f49016e
+msgid "Properly escape symbol characters in tag names (e.g., ``C++``)"
+msgstr ""
+
+#: ../../changelog.rst:332 d4c27bbafbd0427e821e301a503eec07
+msgid "Minor tweaks for Python 3.4 compatibility"
+msgstr ""
+
+#: ../../changelog.rst:333 743111e35a0c4303985dcce214e3e29f
+msgid "Add several new signals"
+msgstr ""
+
+#: ../../changelog.rst:336 46ee1a42a2ac4f688e20db25231a97cc
+msgid "3.3.0 (2013-09-24)"
+msgstr ""
+
+#: ../../changelog.rst:338 d38c96a268fb4928b7884c32f04ea781
+msgid "Drop Python 3.2 support in favor of Python 3.3"
+msgstr ""
+
+#: ../../changelog.rst:339 e4b1b4170e3a4daf85bb3e0b4a33d84c
+msgid ""
+"Add ``Fabfile`` so Fabric can be used for workflow automation instead of "
+"Make"
+msgstr ""
+
+#: ../../changelog.rst:340 8f898752127545598c060470ba4ea5a6
+msgid ""
+"``OUTPUT_RETENTION`` setting can be used to preserve metadata (e.g., VCS "
+"data such as ``.hg`` and ``.git``) from being removed from output "
+"directory"
+msgstr ""
+
+#: ../../changelog.rst:342 3cef6e0824db42ef8eb2a6db21e018c4
+msgid "Tumblr import"
+msgstr ""
+
+#: ../../changelog.rst:343 9b35ec96add44773857342682a38fbe9
+msgid "Improve logic and consistency when cleaning output folder"
+msgstr ""
+
+#: ../../changelog.rst:344 0e3383e3461a44b590b00a88c8543859
+msgid "Improve documentation versioning and release automation"
+msgstr ""
+
+#: ../../changelog.rst:345 ab9935d7e2c84ccb852185870f8d1cc9
+msgid "Improve pagination flexibility"
+msgstr ""
+
+#: ../../changelog.rst:346 92bd1ab368544083ac4e64f5d424c151
+msgid ""
+"Rename signals for better consistency (some plugins may need to be "
+"updated)"
+msgstr ""
+
+#: ../../changelog.rst:347 740eae7ce680434c981b4064809072a3
+msgid ""
+"Move metadata extraction from generators to readers; metadata extraction "
+"no longer article-specific"
+msgstr ""
+
+#: ../../changelog.rst:349 d1ae5b5bc77f4bcaa40d5bd86cdc0fcc
+msgid ""
+"Deprecate ``FILES_TO_COPY`` in favor of ``STATIC_PATHS`` and "
+"``EXTRA_PATH_METADATA``"
+msgstr ""
+
+#: ../../changelog.rst:351 806154386d4c45d9b625087bbd8706bd
+msgid "Summaries in Markdown posts no longer include footnotes"
+msgstr ""
+
+#: ../../changelog.rst:352 1e20db19c60442a4ae4c517d5edaac8c
+msgid ""
+"Remove unnecessary whitespace in output via ``lstrip_blocks`` Jinja "
+"parameter"
+msgstr ""
+
+#: ../../changelog.rst:353 72b17016676643d4863b6da2dc5dd585
+msgid "Move PDF generation from core to plugin"
+msgstr ""
+
+#: ../../changelog.rst:354 c8e9e2beddd242038b0655913de16745
+msgid "Replace ``MARKUP`` setting with ``READERS``"
+msgstr ""
+
+#: ../../changelog.rst:355 39124ff576a145e194694060c394ebea
+msgid "Add warning if img tag is missing ``alt`` attribute"
+msgstr ""
+
+#: ../../changelog.rst:356 039cc780731643f882a0dd52bd7486d9
+msgid "Add support for ``{}`` in relative links syntax, besides ``||``"
+msgstr ""
+
+#: ../../changelog.rst:357 9289f5f1c5f04c5894cb8e7e02f9f5c8
+msgid "Add support for ``{tag}`` and ``{category}`` relative links"
+msgstr ""
+
+#: ../../changelog.rst:358 a214dc13448b479bb7af0a16825457aa
+msgid "Add a ``content_written`` signal"
+msgstr ""
+
+#: ../../changelog.rst:361 5249278a96bc437fa297368c8f672404
+msgid "3.2.1 and 3.2.2"
+msgstr ""
+
+#: ../../changelog.rst:363 3f9b98d264e048949c389dbe3e260652
+msgid "Facilitate inclusion in FreeBSD Ports Collection"
+msgstr ""
+
+#: ../../changelog.rst:366 124cc3f3f8924e918bd0789422649535
+msgid "3.2 (2013-04-24)"
+msgstr ""
+
+#: ../../changelog.rst:368 fa25abf620e84a568df67473d9b3e20f
+msgid "Support for Python 3!"
+msgstr ""
+
+#: ../../changelog.rst:369 b1702663f9ff41e387aa055aa8a80985
+msgid ""
+"Override page save-to location from meta-data (enables using a static "
+"page as the site's home page, for example)"
+msgstr ""
+
+#: ../../changelog.rst:371 3d9f1c80f4c74f0fb655aaff98846e2e
+msgid "Time period archives (per-year, per-month, and per-day archives of posts)"
+msgstr ""
+
+#: ../../changelog.rst:372 ee27abd30d204213967d190e45bc3cce
+msgid "Posterous blog import"
+msgstr ""
+
+#: ../../changelog.rst:373 2614d3717c644bd4b567eb2bbcec9c5b
+msgid "Improve WordPress blog import"
+msgstr ""
+
+#: ../../changelog.rst:374 8e10fa12d60b4473858214e618f934f3
+msgid "Migrate plugins to separate repository"
+msgstr ""
+
+#: ../../changelog.rst:375 a4ff557f266149e992884d5bc180f6fd
+msgid "Improve HTML parser"
+msgstr ""
+
+#: ../../changelog.rst:376 e9a87539173943dcb76ffff618a205cc
+msgid ""
+"Provide ability to show or hide categories from menu using "
+"``DISPLAY_CATEGORIES_ON_MENU`` option"
+msgstr ""
+
+#: ../../changelog.rst:378 721df0da641444c1a41fe72e38bafa20
+msgid "Auto-regeneration can be told to ignore files via ``IGNORE_FILES`` setting"
+msgstr ""
+
+#: ../../changelog.rst:379 2f925e2291c54bc0b6da964d7f17079f
+msgid "Improve post-generation feedback to user"
+msgstr ""
+
+#: ../../changelog.rst:380 bc36457afeaa449583693dcef652e072
+msgid ""
+"For multilingual posts, use meta-data to designate which is the original "
+"and which is the translation"
+msgstr ""
+
+#: ../../changelog.rst:382 8abbe86f8e4a4786886f887bad894983
+msgid "Add ``.mdown`` to list of supported Markdown file extensions"
+msgstr ""
+
+#: ../../changelog.rst:383 84e1d9cee66c4ee3ba779eb697169d35
+msgid "Document-relative URL generation (``RELATIVE_URLS``) is now off by default"
+msgstr ""
+
+#: ../../changelog.rst:386 461aa8ba882c4543980540c6686a69ff
+msgid "3.1 (2012-12-04)"
+msgstr ""
+
+#: ../../changelog.rst:388 ea4445533819403b8a54af8f62d30dab
+msgid ""
+"Importer now stores slugs within files by default. This can be disabled "
+"with the ``--disable-slugs`` option."
+msgstr ""
+
+#: ../../changelog.rst:390 a00bcb155126439ab341cff0f37ecc5a
+msgid "Improve handling of links to intra-site resources"
+msgstr ""
+
+#: ../../changelog.rst:391 5d47bb0eac84452b829ea7a5a7447bdd
+msgid ""
+"Ensure WordPress import adds paragraphs for all types of line endings in "
+"post content"
+msgstr ""
+
+#: ../../changelog.rst:393 6d41430cf1ae4bbe95c7206bed9fe17c
+msgid "Decode HTML entities within WordPress post titles on import"
+msgstr ""
+
+#: ../../changelog.rst:394 17121b597e6148768c531523a9b6f955
+msgid "Improve appearance of LinkedIn icon in default theme"
+msgstr ""
+
+#: ../../changelog.rst:395 cfc8bfbe89c44ce9a30e230f255d79dd
+msgid "Add GitHub and Google+ social icons support in default theme"
+msgstr ""
+
+#: ../../changelog.rst:396 5bd746b4bcc64c7382d492f61d50193c
+msgid "Optimize social icons"
+msgstr ""
+
+#: ../../changelog.rst:397 bdb1513252d54c1f89e9efc11516b368
+msgid ""
+"Add ``FEED_ALL_ATOM`` and ``FEED_ALL_RSS`` to generate feeds containing "
+"all posts regardless of their language"
+msgstr ""
+
+#: ../../changelog.rst:399 6d52c5f3e6e64dcc8b11fb5f80d6df46
+msgid ""
+"Split ``TRANSLATION_FEED`` into ``TRANSLATION_FEED_ATOM`` and "
+"``TRANSLATION_FEED_RSS``"
+msgstr ""
+
+#: ../../changelog.rst:401 12c0a402411f47a4a71f64d7f19efd01
+msgid "Different feeds can now be enabled/disabled individually"
+msgstr ""
+
+#: ../../changelog.rst:402 f7ddae2570b34df1b598fa35239449ad
+msgid ""
+"Allow for blank author: if ``AUTHOR`` setting is not set, author won't "
+"default to ``${USER}`` anymore, and a post won't contain any author "
+"information if the post author is empty"
+msgstr ""
+
+#: ../../changelog.rst:405 e12a883add8d41f1b330e51ace547b06
+msgid "Move LESS and Webassets support from Pelican core to plugin"
+msgstr ""
+
+#: ../../changelog.rst:406 d2e26f930edf4d68801b4e005ab7cdca
+msgid ""
+"The ``DEFAULT_DATE`` setting now defaults to ``None``, which means that "
+"articles won't be generated unless date metadata is specified"
+msgstr ""
+
+#: ../../changelog.rst:408 c198ce6b37c94d98b358cf8aae3fa1c0
+msgid ""
+"Add ``FILENAME_METADATA`` setting to support metadata extraction from "
+"filename"
+msgstr ""
+
+#: ../../changelog.rst:410 c3a2e1677eab4de3a12963b8c13e4875
+msgid ""
+"Add ``gzip_cache`` plugin to compress common text files into a ``.gz`` "
+"file within the same directory as the original file, preventing the "
+"server (e.g. Nginx) from having to compress files during an HTTP call"
+msgstr ""
+
+#: ../../changelog.rst:413 666bac4d13ba42d5b61833beb0950beb
+msgid "Add support for AsciiDoc-formatted content"
+msgstr ""
+
+#: ../../changelog.rst:414 aaf5c771064c4c46975523a15609e6c9
+msgid ""
+"Add ``USE_FOLDER_AS_CATEGORY`` setting so that feature can be toggled "
+"on/off"
+msgstr ""
+
+#: ../../changelog.rst:415 71233f0cf0844770a9374a375bce2ed6
+msgid "Support arbitrary Jinja template files"
+msgstr ""
+
+#: ../../changelog.rst:416 fa2c3365a6c049bdb69a3215fd4010f7
+msgid "Restore basic functional tests"
+msgstr ""
+
+#: ../../changelog.rst:417 925cdeb6a5344275a69e3d93ecc88eea
+msgid ""
+"New signals: ``generator_init``, ``get_generators``, and "
+"``article_generate_preread``"
+msgstr ""
+
+#: ../../changelog.rst:421 a534e61fa0374d0cb03ec9d83b5fe387
+msgid "3.0 (2012-08-08)"
+msgstr ""
+
+#: ../../changelog.rst:423 7ec504fa35f84ec1b47a86fb9ef3b685
+msgid "Refactored the way URLs are handled"
+msgstr ""
+
+#: ../../changelog.rst:424 a268577292d945649ad12e1430ed9eaf
+msgid "Improved the English documentation"
+msgstr ""
+
+#: ../../changelog.rst:425 c694abe18818459d83a25f01c6257d9b
+msgid "Fixed packaging using ``setuptools`` entrypoints"
+msgstr ""
+
+#: ../../changelog.rst:426 81b5a9a2740340e6ad48d2baceef5ebd
+msgid "Added ``typogrify`` support"
+msgstr ""
+
+#: ../../changelog.rst:427 39d0f35b4ee343259ec7375597a718ec
+msgid "Added a way to disable feed generation"
+msgstr ""
+
+#: ../../changelog.rst:428 8eb4aa1d17ff406aaf5be093c4310966
+msgid "Added support for ``DIRECT_TEMPLATES``"
+msgstr ""
+
+#: ../../changelog.rst:429 0b43a8fa70db455696e298f4c11ac0c3
+msgid "Allow multiple extensions for content files"
+msgstr ""
+
+#: ../../changelog.rst:430 89b94d339a3f46f882451d1dfac8df08
+msgid "Added LESS support"
+msgstr ""
+
+#: ../../changelog.rst:431 bb9a3c00bb23405698d39c49b812ec07
+msgid "Improved the import script"
+msgstr ""
+
+#: ../../changelog.rst:432 d4b7b6302e4b48b6990484066099dec1
+msgid "Added functional tests"
+msgstr ""
+
+#: ../../changelog.rst:433 cc8d47d8e96d47c1965b6b721ad32de5
+msgid "Rsync support in the generated Makefile"
+msgstr ""
+
+#: ../../changelog.rst:434 10cb71db95504caf9c45928191f650b0
+msgid "Improved feed support (easily pluggable with Feedburner for instance)"
+msgstr ""
+
+#: ../../changelog.rst:435 61c7cb5819f94c89bd6dc3773375048f
+msgid "Added support for ``abbr`` in reST"
+msgstr ""
+
+#: ../../changelog.rst:436 f65624c8dd3f4047be4adc66a8a9d1f4
+msgid "Fixed a bunch of bugs :-)"
+msgstr ""
+
+#: ../../changelog.rst:439 d87300bfd91e495286e96a06c76fea5a
+msgid "2.8 (2012-02-28)"
+msgstr ""
+
+#: ../../changelog.rst:441 a96f4e4b17034044a7fad630eba6f6c3
+msgid "Dotclear importer"
+msgstr ""
+
+#: ../../changelog.rst:442 769b7e899fe44b2299b3bc021b23724d
+msgid "Allow the usage of Markdown extensions"
+msgstr ""
+
+#: ../../changelog.rst:443 c11b737547f44ee4b9f206d78fd69034
+msgid "Themes are now easily extensible"
+msgstr ""
+
+#: ../../changelog.rst:444 22b0eea97e5c4d5ea4615961685ddfda
+msgid "Don't output pagination information if there is only one page"
+msgstr ""
+
+#: ../../changelog.rst:445 739a53e452714197918fdb7c730685c2
+msgid "Add a page per author, with all their articles"
+msgstr ""
+
+#: ../../changelog.rst:446 6b9d84b09f954dba8e2ad225e26ad68a
+msgid "Improved the test suite"
+msgstr ""
+
+#: ../../changelog.rst:447 6099f1c52f7c48adad09f9b84f50f181
+msgid "Made the themes easier to extend"
+msgstr ""
+
+#: ../../changelog.rst:448 e4090cb5f1634fe0b30e498e8f1c0eca
+msgid "Removed Skribit support"
+msgstr ""
+
+#: ../../changelog.rst:449 04ff51eeefd24306804c5a2daa98d59e
+msgid "Added a ``pelican-quickstart`` script"
+msgstr ""
+
+#: ../../changelog.rst:450 550158557c904ad8abe330a0b86e6755
+msgid "Fixed timezone-related issues"
+msgstr ""
+
+#: ../../changelog.rst:451 f41a6fafa9d548adbae1dfc7276a7f3a
+msgid "Added some scripts for Windows support"
+msgstr ""
+
+#: ../../changelog.rst:452 e8b30590d7c64808b604f03d4bf25ffc
+msgid "Date can be specified in seconds"
+msgstr ""
+
+#: ../../changelog.rst:453 bbdf1c456cc3417e876855d8b792753c
+msgid "Never fail when generating posts (skip and continue)"
+msgstr ""
+
+#: ../../changelog.rst:454 33545506148f48c7a1f42d12535604ad
+msgid "Allow the use of future dates"
+msgstr ""
+
+#: ../../changelog.rst:455 1d56de44e22c432eb61fbd23fe27ae88
+msgid "Support having different timezones per language"
+msgstr ""
+
+#: ../../changelog.rst:456 0002c845a16a4d5bb19eeca4dedb0ce9
+msgid "Enhanced the documentation"
+msgstr ""
+
+#: ../../changelog.rst:459 2dd8c562cd44466cbbc868023bc8eef6
+msgid "2.7 (2011-06-11)"
+msgstr ""
+
+#: ../../changelog.rst:461 6383d280fbbf47e99be6cbceaaa30245
+msgid "Use ``logging`` rather than echoing to stdout"
+msgstr ""
+
+#: ../../changelog.rst:462 80e585445f284f95be38a221068c817d
+msgid "Support custom Jinja filters"
+msgstr ""
+
+#: ../../changelog.rst:463 a2431e6f9cd041d7ae9a81ee9ea1f1d3
+msgid "Compatibility with Python 2.5"
+msgstr ""
+
+#: ../../changelog.rst:464 8cdec91cfae54eef979319ffcd7b2b4b
+msgid "Added a theme manager"
+msgstr ""
+
+#: ../../changelog.rst:465 53823ba8924f4092a13f30d612b6d147
+msgid "Packaged for Debian"
+msgstr ""
+
+#: ../../changelog.rst:466 dcf480ab75f849e78f2e15e0de4880c9
+msgid "Added draft support"
+msgstr ""
+
+#: ../../changelog.rst:469 9e46e5ecc5aa48ed9c973f181250bb2d
+msgid "2.6 (2011-03-08)"
+msgstr ""
+
+#: ../../changelog.rst:471 3b00b44b0dc74320bcc30ac3c3b8d43f
+msgid "Changes in the output directory structure"
+msgstr ""
+
+#: ../../changelog.rst:472 7edd59c2885748b18242900bc717e6f2
+msgid "Makes templates easier to work with / create"
+msgstr ""
+
+#: ../../changelog.rst:473 80ecbc256d074c0ab966b3f8f90b2fa7
+msgid "Added RSS support (was Atom-only)"
+msgstr ""
+
+#: ../../changelog.rst:474 6bcd42cb56ae4e52b1fd66833cad6bd3
+msgid "Added tag support for the feeds"
+msgstr ""
+
+#: ../../changelog.rst:475 e8875e8c6317488eb0fa76f5d444763f
+msgid "Enhance the documentation"
+msgstr ""
+
+#: ../../changelog.rst:476 feb91b6347cb467ba693cb55a2cd8a00
+msgid "Added another theme (brownstone)"
+msgstr ""
+
+#: ../../changelog.rst:477 3e8cd0da99fe408bb66b8db1caaa336b
+msgid "Added translations"
+msgstr ""
+
+#: ../../changelog.rst:478 888218f74f754c209363573264452100
+msgid "Added a way to use cleaner URLs with a rewrite url module (or equivalent)"
+msgstr ""
+
+#: ../../changelog.rst:479 5006a51a923042dcabda9843b155d177
+msgid "Added a tag cloud"
+msgstr ""
+
+#: ../../changelog.rst:480 a329ec582419436392aea3556205352c
+msgid ""
+"Added an autoreloading feature: the blog is automatically regenerated "
+"each time a modification is detected"
+msgstr ""
+
+#: ../../changelog.rst:482 8b136937ff5c42b6a9d4ca2c09f49399
+msgid "Translate the documentation into French"
+msgstr ""
+
+#: ../../changelog.rst:483 00b39926200d4f1389445e6f7a25ea34
+msgid "Import a blog from an RSS feed"
+msgstr ""
+
+#: ../../changelog.rst:484 92dd7ebe963e4c3da3dd0b138d8c0cd7
+msgid "Pagination support"
+msgstr ""
+
+#: ../../changelog.rst:485 45dc61ad8c664e1e84511003c2431e7f
+msgid "Added Skribit support"
+msgstr ""
+
+#: ../../changelog.rst:488 17729e7145b04f21b6adef1c94284e4b
+msgid "2.5 (2010-11-20)"
+msgstr ""
+
+#: ../../changelog.rst:490 44ae6d5ba68944cea82d7b3598be287e
+msgid "Import from WordPress"
+msgstr ""
+
+#: ../../changelog.rst:491 a0af2d8823354b8fa048b456f9d0df25
+msgid "Added some new themes (martyalchin / wide-notmyidea)"
+msgstr ""
+
+#: ../../changelog.rst:492 ec519864fa79463b8eea11f06934cbc5
+msgid "First bug report!"
+msgstr ""
+
+#: ../../changelog.rst:493 7d38312ffc1f4589ad54b2d019cad3ea
+msgid "Linkedin support"
+msgstr ""
+
+#: ../../changelog.rst:494 99a73194501a4469acac9ffdd791502f
+msgid "Added a FAQ"
+msgstr ""
+
+#: ../../changelog.rst:495 49dc1d7af56c43a8b21e3d0e0bf141ad
+msgid "Google Analytics support"
+msgstr ""
+
+#: ../../changelog.rst:496 59edf76455f2489993739d027964bb63
+msgid "Twitter support"
+msgstr ""
+
+#: ../../changelog.rst:497 9c2d230b25e24b179049dc9e0332401c
+msgid "Use relative URLs, not static ones"
+msgstr ""
+
+#: ../../changelog.rst:500 fc4e0772192648cd89baed818dbeb908
+msgid "2.4 (2010-11-06)"
+msgstr ""
+
+#: ../../changelog.rst:502 d01de90563a94bafae690740613aa682
+msgid "Minor themes changes"
+msgstr ""
+
+#: ../../changelog.rst:503 38a95f8b00684dc3ab279840640a01d8
+msgid "Add Disqus support (so we have comments)"
+msgstr ""
+
+#: ../../changelog.rst:504 13dca871c120491a90240c43c7d0f4c7
+msgid "Another code refactoring"
+msgstr ""
+
+#: ../../changelog.rst:505 87ec5e2d8b80482aac6e0a82f31c0d12
+msgid "Added config settings about pages"
+msgstr ""
+
+#: ../../changelog.rst:506 30c338ee5d85462588119841675c73f4
+msgid "Blog entries can also be generated in PDF"
+msgstr ""
+
+#: ../../changelog.rst:509 6d1ebe0620ff46939743b2fe2e9f1683
+msgid "2.3 (2010-10-31)"
+msgstr ""
+
+#: ../../changelog.rst:511 3df14b83afaa446ca893c157189e33fb
+msgid "Markdown support"
+msgstr ""
+
+#: ../../changelog.rst:514 91b45ea2e78047ccbbd97c7059930864
+msgid "2.2 (2010-10-30)"
+msgstr ""
+
+#: ../../changelog.rst:516 4b96d6c2c47d463ebb66d1eaeb1f004e
+msgid "Prettify output"
+msgstr ""
+
+#: ../../changelog.rst:517 cd805a3c55c84ddd89080a4912d91633
+msgid "Manages static pages as well"
+msgstr ""
+
+#: ../../changelog.rst:520 bc8859b0bf4043e09aed54af4b3c6ba7
+msgid "2.1 (2010-10-30)"
+msgstr ""
+
+#: ../../changelog.rst:522 3146db5382224eddad41228f6f539e4c
+msgid "Make notmyidea the default theme"
+msgstr ""
+
+#: ../../changelog.rst:525 f1bff0048805473d90461c68f8c82f07
+msgid "2.0 (2010-10-30)"
+msgstr ""
+
+#: ../../changelog.rst:527 9c0181b93ed34eaa87a8e323a773a4c9
+msgid "Refactoring to be more extensible"
+msgstr ""
+
+#: ../../changelog.rst:528 878c1cc7b2bb4adbb1684439b029cd14
+msgid "Change into the setting variables"
+msgstr ""
+
+#: ../../changelog.rst:531 ca506f63c6474fa4ba68a7b57a840e81
+msgid "1.2 (2010-09-28)"
+msgstr ""
+
+#: ../../changelog.rst:533 eef62c1f5bff457eba9733aba004b18d
+msgid "Added a debug option"
+msgstr ""
+
+#: ../../changelog.rst:534 5c800901f23b4dceac320db21cb1e3db
+msgid "Added per-category feeds"
+msgstr ""
+
+#: ../../changelog.rst:535 d51b96b46a2b4dc09088ad32fbc61bbb
+msgid "Use filesystem to get dates if no metadata is provided"
+msgstr ""
+
+#: ../../changelog.rst:536 9b6420ecf5fb459d885d70db9190ad3b
+msgid "Add Pygments support"
+msgstr ""
+
+#: ../../changelog.rst:539 5ccc5d9fa9424ec8896c57c3d62e1b6e
+msgid "1.1 (2010-08-19)"
+msgstr ""
+
+#: ../../changelog.rst:541 a992372f04e345b5b37b6e20891b9b60
+msgid "First working version"
+msgstr ""
diff --git a/docs/locale/zh_CN/LC_MESSAGES/content.po b/docs/locale/zh_CN/LC_MESSAGES/content.po
new file mode 100644
index 00000000..e180a866
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/content.po
@@ -0,0 +1,1074 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-09-15 09:23+0800\n"
+"PO-Revision-Date: 2024-06-25 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../content.rst:2 0e0d4e5751154cd4a5002b3f93cce14a
+msgid "Writing content"
+msgstr "创作内容"
+
+#: ../../content.rst:5 4316c31e97f740239cb3daaa533c0b64
+msgid "Articles and pages"
+msgstr "文章和页面"
+
+#: ../../content.rst:7 66e59f17488f4914a6d5c4538214dd91
+msgid ""
+"Pelican considers \"articles\" to be chronological content, such as posts"
+" on a blog, and thus associated with a date."
+msgstr "Pelican将“文章”(article)视为有时间顺序的内容,例如博客上的博文就是文章。"
+
+#: ../../content.rst:10 ed244e3e671f450daf0617a80274878b
+msgid ""
+"The idea behind \"pages\" is that they are usually not temporal in nature"
+" and are used for content that does not change very often (e.g., "
+"\"About\" or \"Contact\" pages)."
+msgstr "“页面”(page)指的是不经常改变的内容,例如“关于”“联系我们”这样的。"
+
+#: ../../content.rst:14 f30d12684e0043438418655ba9f5cf25
+msgid "You can find sample content in the repository at ``samples/content/``."
+msgstr ""
+"在代码仓库的 ``samples/content/`` "
+"文件夹下有一些内容示例供您查看。(译者注:原文档中还有post与content的说法,一般既指代文章又指代页面,后文统一将其翻译为推文)"
+
+#: ../../content.rst:19 370562db18eb42f19935009d087595b4
+msgid "File metadata"
+msgstr "文件元数据"
+
+#: ../../content.rst:21 e9e758d40aeb42a78a5e25ddbca35a3b
+msgid ""
+"Pelican tries to be smart enough to get the information it needs from the"
+" file system (for instance, about the category of your articles), but "
+"some information you need to provide in the form of metadata inside your "
+"files."
+msgstr "Pelican可以从文件系统中自动地获取一些信息(例如文章的分类),但是有些信息需要您以元数据的形式在文件中提供。"
+
+#: ../../content.rst:25 276a3d27de8c41a784b3c4fa6b0b9f1b
+msgid ""
+"If you are writing your content in reStructuredText format, you can "
+"provide this metadata in text files via the following syntax (give your "
+"file the ``.rst`` extension)::"
+msgstr "如果您用reStructuredText的格式进行内容创作,您可以按照下面的语法在文本文件中提供元数据(请给文本文件加上 ``.rst`` 后缀):"
+
+#: ../../content.rst:40 b5d99eedf95a4b6bbf760eccb4add31b
+msgid ""
+"Author and tag lists may be semicolon-separated instead, which allows you"
+" to write authors and tags containing commas::"
+msgstr "如果有多个作者或多个文章标签,需要将他们以分号分隔,这样就可以在作者或标签中使用逗号了:"
+
+#: ../../content.rst:46 18ae0e8b1cae406381a546bf2462c1e6
+msgid ""
+"Pelican implements an extension to reStructuredText to enable support for"
+" the ``abbr`` HTML tag. To use it, write something like this in your "
+"post::"
+msgstr "Pelican在reStructuredText上实现了 ``abbr`` HTML标签的使用支持。在正文部分按照下面的形式书写即可。"
+
+#: ../../content.rst:51 62c068f033f0498d888dd72f23f9d231
+msgid ""
+"You can also use Markdown syntax (with a file ending in ``.md``, "
+"``.markdown``, ``.mkd``, or ``.mdown``). Markdown generation requires "
+"that you first explicitly install the Python-Markdown_ package, which can"
+" be done via ``pip install Markdown``."
+msgstr ""
+"Pelican同时也支持Markdown语法(文件的扩展名需要为 ``.md`` 、 ``.markdown``、 ``.mkd`` 或 "
+"``.mdown`` )要让Pelican进行Markdown的生成,需要先通过 ``pip install Markdown`` 安装 "
+"Python-Markdown_ 。"
+
+#: ../../content.rst:56 f39e1de0f9ea4533942c5bf0bff7866f
+msgid ""
+"Pelican also supports `Markdown Extensions`_, which might have to be "
+"installed separately if they are not included in the default ``Markdown``"
+" package and can be configured and loaded via the ``MARKDOWN`` setting."
+msgstr ""
+"Pelican同样支持 `Markdown扩展`_ ,可以是 ``Markdown`` 包自带的扩展,也可以是另外安装的,可以通过 "
+"``MARKDOWN`` 配置项管理这些扩展。"
+
+#: ../../content.rst:60 c9f3ab98c3d54b53bf647ba9202b5386
+msgid "Metadata syntax for Markdown posts should follow this pattern::"
+msgstr "Markdown中的元数据语法需要按照下面的格式书写:"
+
+#: ../../content.rst:73 ba840c208e4b4198ac0a2bd672a94f36
+msgid ""
+"You can also have your own metadata keys (so long as they don't conflict "
+"with reserved metadata keywords) for use in your templates. The following"
+" table contains a list of reserved metadata keywords:"
+msgstr "您也可以定义自己的元数据类型(只要和保留的元数据关键字不冲突),这些自定义的元数据关键字可以用在自定义的模板中。下面的列出了所有保留的元数据关键字。"
+
+#: ../../content.rst:78 a9537c5593d9458d9193dacc82c27f2f
+msgid "Metadata"
+msgstr "元数据类型"
+
+#: ../../content.rst:78 ../../content.rst:548 827ac866a3914692ac5fc9eaa1921aac
+#: a55315aa4aee4e30a7768bc54d7063da
+msgid "Description"
+msgstr "描述"
+
+#: ../../content.rst:80 d5e5b3902b9f46e3a827c551e26d84bd
+msgid "``title``"
+msgstr "``title``"
+
+#: ../../content.rst:80 07eb7d1b1a5f458084564729052749e7
+msgid "Title of the article or page"
+msgstr "文章或页面的标题"
+
+#: ../../content.rst:81 37abd449ffca4436a505f0dc35343cea
+msgid "``date``"
+msgstr "``date``"
+
+#: ../../content.rst:81 a13a424e96f643068af63b0d0d2dbb27
+msgid "Publication date (e.g., ``YYYY-MM-DD HH:SS``)"
+msgstr "发布日期(需要以 ``YYYY-MM-DD HH:SS`` 的格式)"
+
+#: ../../content.rst:82 7534c5908891457797988ef7a67b17db
+msgid "``modified``"
+msgstr "``modified``"
+
+#: ../../content.rst:82 6cc7d4c20ee44e31bb54173b24aa9afe
+msgid "Modification date (e.g., ``YYYY-MM-DD HH:SS``)"
+msgstr "最后修改日期(需要以 ``YYYY-MM-DD HH:SS`` 的格式)"
+
+#: ../../content.rst:83 0f7d30bb91bf46f7a0e2dd5ab186955d
+msgid "``tags``"
+msgstr "``tags``"
+
+#: ../../content.rst:83 e07fee37f1de414f82b38e7ff5e9051b
+msgid "Content tags, separated by commas"
+msgstr "推文标签,以逗号分隔"
+
+#: ../../content.rst:84 cc730907be1c4bb6a4d1f4e551f1bb13
+msgid "``keywords``"
+msgstr "``keywords``"
+
+#: ../../content.rst:84 b4185fda72084329b551f26b6eff5bd5
+msgid "Content keywords, separated by commas (HTML content only)"
+msgstr "推文关键字,以逗号分隔(只能在HTML内容中使用)"
+
+#: ../../content.rst:85 98438d6e0fbf4783a580516079fa5f3b
+msgid "``category``"
+msgstr "``category``"
+
+#: ../../content.rst:85 48e04733764e4962bfe4d16828b34d79
+msgid "Content category (one only — not multiple)"
+msgstr "推文分类(只能归属到一个分类中,不支持多个)"
+
+#: ../../content.rst:86 275265cdeaaf4515b8f84dd79d29e181
+msgid "``slug``"
+msgstr "``slug``"
+
+#: ../../content.rst:86 d910b7a82ea540179d561f639e531b9d
+msgid "Identifier used in URLs and translations"
+msgstr "URL和翻译的唯一标识符"
+
+#: ../../content.rst:87 ac2a927028d647a0b4f5edb14e5b1851
+msgid "``author``"
+msgstr "``author``"
+
+#: ../../content.rst:87 bd27267c861f470db23499a67a631854
+msgid "Content author, when there is only one"
+msgstr "当只有一个作者时可以使用这个元数据"
+
+#: ../../content.rst:88 9616ecb488914e4eaa192ecb4e437ba0
+msgid "``authors``"
+msgstr "``authors``"
+
+#: ../../content.rst:88 762660408c274f5690dba81dcc88c662
+msgid "Content authors, when there are multiple"
+msgstr "当有多个作者时需要使用这个元数据"
+
+#: ../../content.rst:89 40d65df77e0f4e75a26615d60775a382
+msgid "``summary``"
+msgstr "``summary``"
+
+#: ../../content.rst:89 f072a97cf1c54b7fbd383f205732f1c2
+msgid "Brief description of content for index pages"
+msgstr "简短的推文概要,会显示在首页上"
+
+#: ../../content.rst:90 69018dfa7f9b4e74b518fc1940af8908
+msgid "``lang``"
+msgstr "``lang``"
+
+#: ../../content.rst:90 f139c5b2a2774ee3bb83d4bd3b523a93
+msgid "Content language ID (``en``, ``fr``, etc.)"
+msgstr "推文所用语言的ID(例如 ``en`` 、 ``fr`` 、 ``zh-cn`` 等)"
+
+#: ../../content.rst:91 13757ce4c6a84096b4d131232eaeb8b4
+msgid "``translation``"
+msgstr "``translation``"
+
+#: ../../content.rst:91 9b3f475397bc4d60a1eb911f6763285f
+msgid "If content is a translation of another (``true`` or ``false``)"
+msgstr "手动指定当前内容是否是某个翻译版本(该元数据的值只能是 ``true`` 或 ``false``)"
+
+#: ../../content.rst:92 3f294461641949eead16c79e7bffdb22
+msgid "``status``"
+msgstr "``status``"
+
+#: ../../content.rst:92 f6ab65a6adf64379a14fb89d300d9eaa
+msgid "Content status: ``draft``, ``hidden``, ``skip``, or ``published``"
+msgstr "推文的状态: ``draft``、 ``hidden`` 、 ``skip`` 或 ``published`` "
+
+#: ../../content.rst:93 d9aefdcc77aa462d9934eb49f2b39095
+msgid "``template``"
+msgstr "``template``"
+
+#: ../../content.rst:93 41ecae4039714f31b0220f0d0f45a0c7
+msgid "Name of template to use to generate content (without extension)"
+msgstr "用于指定要使用的生成模板,只需要写模板的名字,不需要模板文件的后缀名"
+
+#: ../../content.rst:94 892e239c7a9145beb61b2f583284f448
+msgid "``save_as``"
+msgstr "``save_as``"
+
+#: ../../content.rst:94 3bc3792a6a5c4e79bcf8f77fc48f313b
+msgid "Save content to this relative file path"
+msgstr "将内容保存到指定的相对文件路径"
+
+#: ../../content.rst:95 8c3ed87a54734ca1bba051448d8169f9
+msgid "``url``"
+msgstr "``url``"
+
+#: ../../content.rst:95 2b55b515c7ce40e48eae20fbc67107bb
+msgid "URL to use for this article/page"
+msgstr "指定本篇文章或页面要使用的URL"
+
+#: ../../content.rst:98 81c7cc35f7b74566b7dd9083c2fc17f1
+msgid ""
+"Readers for additional formats (such as AsciiDoc_) are available via "
+"plugins, which you can find via the `Pelican Plugins`_ collection as well"
+" as the legacy `pelican-plugins`_ repository."
+msgstr ""
+"对其他格式的支持(例如 AsciiDoc_ )可以通过插件实现,在 `Pelican插件`_ 集中可以查看所有插件。当然,在老的 "
+"`pelican-plugins`_ 仓库中也可以查看。"
+
+#: ../../content.rst:102 b808c2914ee14c1380fe53e5e1f378f7
+msgid ""
+"Pelican can also process HTML files ending in ``.html`` and ``.htm``. "
+"Pelican interprets the HTML in a very straightforward manner, reading "
+"metadata from ``meta`` tags, the title from the ``title`` tag, and the "
+"body out from the ``body`` tag::"
+msgstr ""
+"Pelican还能处理后缀名为 ``.html`` 和 ``.htm`` "
+"的HTML文件Pelican在解释转换HTML文件时用的方法非常直接,会从 ``meta`` HTML标签中获取元数据信息,从 ``title``"
+" HTML标签中获取标题,从 ``body`` 标签中获取文章的正文内容:"
+
+#: ../../content.rst:122 289c3761b4b94691bee5ef07e8ab25ff
+msgid ""
+"With HTML, there is one simple exception to the standard metadata: tags "
+"can be specified either via the ``tags`` metadata, as is standard in "
+"Pelican, or via the ``keywords`` metadata, as is standard in HTML. The "
+"two can be used interchangeably."
+msgstr ""
+"当使用HTML文件时,上述的众多元数据中有一个比较特殊的存在——tags。这个元数据在HTML文档中有两种方式可以指定,一种是Pelican中定义的"
+" ``tags`` (上面的例子中用的就是这种);另一种是使用HTML中定义的 ``keywords`` "
+"(即将name属性的“tags”换成“keywords”)。"
+
+#: ../../content.rst:127 9af1403c5c624860bd73aba6f6ad642f
+msgid ""
+"Note that, aside from the title, none of this content metadata is "
+"mandatory: if the date is not specified and ``DEFAULT_DATE`` is set to "
+"``'fs'``, Pelican will rely on the file's \"mtime\" timestamp, and the "
+"category can be determined by the directory in which the file resides. "
+"For example, a file located at ``python/foobar/myfoobar.rst`` will have a"
+" category of ``foobar``. If you would like to organize your files in "
+"other ways where the name of the subfolder would not be a good category "
+"name, you can set the setting ``USE_FOLDER_AS_CATEGORY`` to ``False``. "
+"When parsing dates given in the page metadata, Pelican supports the W3C's"
+" `suggested subset ISO 8601`__."
+msgstr ""
+"需要注意的是,除了title外,其他所有元数据都是可以缺省的。若未指定日期元数据并且将 ``DEFAULT_DATE`` 设为了 "
+"``'fs'``,Pelican就会从文件的 “mtime” 时间戳中获取日期信息;文件所在目录的名称会被作为category。例如 "
+"``python/foobar/myfoobar.rst`` 的category元数据值就会被设为 ``foobar`` "
+"。如果您不希望子目录的名称成为category的值,则需要在设置中将 ``USE_FOLDER_AS_CATEGORY`` 设为 "
+"``False`` 。进行日期元数据的解析时,Pelican支持W3C的 `suggested subset ISO 8601`__ 标准。"
+
+#: ../../content.rst:137 0f142fac1e9e41eeb0cf4cc70a42f72b
+msgid ""
+"So the title is the only required metadata. If that bothers you, worry "
+"not. Instead of manually specifying a title in your metadata each time, "
+"you can use the source content file name as the title. For example, a "
+"Markdown source file named ``Publishing via Pelican.md`` would "
+"automatically be assigned a title of *Publishing via Pelican*. If you "
+"would prefer this behavior, add the following line to your settings "
+"file::"
+msgstr ""
+"总而言之,标题是唯一必须指定的元数据。如果您甚至懒得写标题,也不用担心,Pelican会自动将文件名作为内容的标题。例如,Markdown源文件 "
+"``Publishing via Pelican.md`` 的标题会自动设为 *Publishing via "
+"Pelican*。如果您希望启用这个特性,请在设置文件中添加下面这么一行:"
+
+#: ../../content.rst:148 481919b7e3974c8293d420886105941f
+msgid ""
+"When experimenting with different settings (especially the metadata ones)"
+" caching may interfere and the changes may not be visible. In such cases "
+"disable caching with ``LOAD_CONTENT_CACHE = False`` or use the "
+"``--ignore-cache`` command-line switch."
+msgstr ""
+"在您尝试不同的设置时(特别是在设置元数据时),缓存可能会对您造成干扰,导致设置更改不起作用。若您遇到了这种问题,可以在配置文件中加上 "
+"``LOAD_CONTENT_CACHE = False`` ,或是在使用命令行生成站点时加上 ``--ignore-cache`` 参数。"
+
+#: ../../content.rst:155 466fa8d713b343d1a8ae8266c3031479
+msgid ""
+"``modified`` should be last time you updated the article, and defaults to"
+" ``date`` if not specified. Besides you can show ``modified`` in the "
+"templates, feed entries in feed readers will be updated automatically "
+"when you set ``modified`` to the current date after you modified your "
+"article."
+msgstr ""
+"``modified`` 元数据中应该为文章最后一次的修改时间,若没有指定,会自动与 ``date`` 保持一致。在您修改文章并将 "
+"``modified`` 设为当前日期后,除了在模板中显示 ``modified`` 之外,feed阅读器中的feed条目也会自动更新。"
+
+#: ../../content.rst:160 e7c9358cd2a74e64863af04736d10775
+msgid ""
+"``authors`` is a comma-separated list of article authors. If there's only"
+" one author you can use ``author`` field."
+msgstr "``authors`` 元数据中是文章作者的列表,各个作者之间用逗号分隔。若只有一个作者,可以使用 ``author`` 。"
+
+#: ../../content.rst:163 15bdeea8538244948ca509ee57ef8f63
+msgid ""
+"If you do not explicitly specify summary metadata for a given post, the "
+"``SUMMARY_MAX_LENGTH`` setting can be used to specify how many words from"
+" the beginning of an article are used as the summary. You can also use an"
+" article's first N paragraphs as its summary using the "
+"``SUMMARY_MAX_PARAGRAPHS`` setting. If both settings are in use, the "
+"specified number of paragraphs will be used but may be truncated to "
+"respect the specified maximum length."
+msgstr ""
+"若您没有显式地指定summary元数据,Pelican会自动从推文开头截取 ``SUMMARY_MAX_LENGTH`` "
+"指定长度的内容作为summary。另外,您也可以使用配置项 ``SUMMARY_MAX_PARAGRAPHS`` "
+"指定推文开头前N段内容作为summary。若同时指定了这两个配置项,首先会考虑 ``SUMMARY_MAX_PARAGRAPHS`` "
+",若前N段的总长度超过 ``SUMMARY_MAX_LENGTH`` ,还是会按照 ``SUMMARY_MAX_LENGTH`` 进行截断。"
+
+#: ../../content.rst:170 64a7dcd4911447338ac1871083242a83
+msgid ""
+"You can also extract any metadata from the filename through a regular "
+"expression to be set in the ``FILENAME_METADATA`` setting. All named "
+"groups that are matched will be set in the metadata object. The default "
+"value for the ``FILENAME_METADATA`` setting will only extract the date "
+"from the filename. For example, if you would like to extract both the "
+"date and the slug, you could set something like: "
+"``'(?P\\d{4}-\\d{2}-\\d{2})_(?P.*)'``"
+msgstr ""
+"您可以通过 ``FILENAME_METADATA`` "
+"设置来使用正则表达式从文件名中提取元数据。正则匹配到的每个命名分组都被看成一个元数据。预设的 ``FILENAME_METADATA`` "
+"只会从文件名中提取date和slug。例如,可以使用 "
+"``'(?P\\d{4}-\\d{2}-\\d{2})_(?P.*)'`` 提取date和slug。"
+
+#: ../../content.rst:177 0b6aaca5fc60494fafd2bdf345f25ab3
+msgid ""
+"Please note that the metadata available inside your files takes "
+"precedence over the metadata extracted from the filename."
+msgstr "请注意,您在推文中直接指定的元数据的优先级是大于从文件名中提取的。"
+
+#: ../../content.rst:181 463df99e715d44c09a48770ddda1e139
+msgid "Pages"
+msgstr "页面"
+
+#: ../../content.rst:183 d2dd51b7abe14dc4921adcf50b8218fb
+msgid ""
+"If you create a folder named ``pages`` inside the content folder, all the"
+" files in it will be used to generate static pages, such as **About** or "
+"**Contact** pages. (See example filesystem layout below.)"
+msgstr ""
+"如果您在content文件夹下创建了一个 ``pages`` 文件夹,那么Pelican会为其中的每个文件生成一个例如 **关于** "
+"、**联系我们** 这样的静态页面。(具体可以看下面项目文件组织的例子)"
+
+#: ../../content.rst:187 3ac83019ba9c44e781a7b67c837c99d6
+msgid ""
+"You can use the ``DISPLAY_PAGES_ON_MENU`` setting to control whether all "
+"those pages are displayed in the primary navigation menu. (Default is "
+"``True``.)"
+msgstr "您可以通过 ``DISPLAY_PAGES_ON_MENU`` 设置来决定页面是否被列在主导航菜单中(默认值为 ``True`` )。"
+
+#: ../../content.rst:190 56486e599f334e0fbc976bcf2d22bd5e
+msgid ""
+"If you want to exclude any pages from being linked to or listed in the "
+"menu, then add a ``status: hidden`` attribute to its metadata. This is "
+"useful for things like making error pages that fit the generated theme of"
+" your site."
+msgstr ""
+"如果您希望让某些页面不会被链接并且也不列在任何菜单中,可以为它加上元数据属性 ``status: hidden`` "
+"。这在将错误页面适配到所用主题时很有用。"
+
+#: ../../content.rst:195 0205a4cab1a040a4aef74a3c375855a4
+msgid "Static content"
+msgstr "静态内容"
+
+#: ../../content.rst:197 2a86301465bd4f41944964cb0edf1572
+msgid ""
+"Static files are files other than articles and pages that are copied to "
+"the output folder as-is, without processing. You can control which static"
+" files are copied over with the ``STATIC_PATHS`` setting of the project's"
+" ``pelicanconf.py`` file. Pelican's default configuration includes the "
+"``images`` directory for this, but others must be added manually. In "
+"addition, static files that are explicitly linked to are included (see "
+"below)."
+msgstr ""
+"静态文件与文章、页面不同,会原模原样地复制到输出文件夹中。当然,您也通过设置 ``STATIC_PATHS`` "
+"更改复制时的目标文件夹。Pelican的默认配置中只包含了 ``images`` "
+"一个文件夹,其他的需要手动添加。另外静态文件也包含那些被显式链接的(详见后文)。"
+
+#: ../../content.rst:206 3b74472b747e4cd494aae142ec4deecc
+msgid ""
+"In the default configuration, all files with a valid content file suffix "
+"(``.html``, ``.rst``, ``.md``, ...) get processed by the article and page"
+" generators *before* the static generator. This is avoided by altering "
+"the ``*_EXCLUDE`` settings appropriately."
+msgstr ""
+"在默认配置下,所有后缀名有效的文件( ``.html`` 、 ``.rst`` 、 ``.md`` , "
+"...)都会由文章/页面生成器处理,这是在静态文件处理之前完成的。若这些文件中的某一些是静态文件,可以合理使用 ``*_EXCLUDE`` "
+"配置项将他们排除(例如 ``ARTICLE_EXCLUDES`` 、 ``PAGE_EXCLUDES``)。"
+
+#: ../../content.rst:212 ab263a1d5b5a4fb0a705257701b8b6c3
+msgid "Mixed content in the same directory"
+msgstr "在同一个目录下存放不同类型的内容"
+
+#: ../../content.rst:214 dfec139d8f98465ea117dcd02f3e7870
+msgid ""
+"Starting with Pelican 3.5, static files can safely share a source "
+"directory with page source files, without exposing the page sources in "
+"the generated site. Any such directory must be added to both "
+"``STATIC_PATHS`` and ``PAGE_PATHS`` (or ``STATIC_PATHS`` and "
+"``ARTICLE_PATHS``). Pelican will identify and process the page source "
+"files normally, and copy the remaining files as if they lived in a "
+"separate directory reserved for static files."
+msgstr ""
+"从Pelican 3.5开始,静态文件就可以和页面源文件安全地放在同一目录下了。这些包含了不同类型内容文件的目录需要添加到 "
+"``STATIC_PATHS`` 和 ``PAGE_PATHS`` 中(或者 ``STATIC_PATHS`` 和 "
+"``ARTICLE_PATHS`` "
+"中)。Pelican会正常地识别和处理文章和页面源文件,然后再把静态文件复制,和处理处于单独一个文件夹的静态文件行为一致。"
+
+#: ../../content.rst:221 de484f74c05a48e4ac84631e56309bf6
+msgid ""
+"Note: Placing static and content source files together in the same source"
+" directory does not guarantee that they will end up in the same place in "
+"the generated site. The easiest way to do this is by using the "
+"``{attach}`` link syntax (described below). Alternatively, the "
+"``STATIC_SAVE_AS``, ``PAGE_SAVE_AS``, and ``ARTICLE_SAVE_AS`` settings "
+"(and the corresponding ``*_URL`` settings) can be configured to place "
+"files of different types together, just as they could in earlier versions"
+" of Pelican."
+msgstr ""
+"请注意:Pelican不保证放在同一个源目录下的静态文件和内容文件在站点生成完后最终出现在同一个地方。要让他们出现在一个地方,可以使用 "
+"``{attach}`` 链接语法(下面会提到)。此外,还可以通过设置 ``STATIC_SAVE_AS`` 、 ``PAGE_SAVE_AS``"
+" 和 ``ARTICLE_SAVE_AS`` (还有相应的 ``*_URL`` 设置)让不同类型的文件最终放在一起。"
+
+#: ../../content.rst:232 6733f6cc9bbb4ee0995d7f818c24b850
+msgid "Linking to internal content"
+msgstr "内部链接"
+
+#: ../../content.rst:234 e0f9e61fef924c82aa7950ad20c0b686
+msgid ""
+"From Pelican 3.1 onwards, it is now possible to specify intra-site links "
+"to files in the *source content* hierarchy instead of files in the "
+"*generated* hierarchy. This makes it easier to link from the current post"
+" to other content that may be sitting alongside that post (instead of "
+"having to determine where the other content will be placed after site "
+"generation)."
+msgstr ""
+"从Pelican 3.1开始,站内链接可以在 *源文件* 层次下指定,而不是只能在 *生成后的站点* "
+"层次下指定。当需要在当前推文链接到邻近位置的内容时,可以直接从源内容文件的位置开始链接(而不需要考虑在站点生成后文件会被放在哪儿)。"
+
+#: ../../content.rst:240 8de8953b665841818066d12cec9631d4
+msgid ""
+"To link to internal content (files in the ``content`` directory), use the"
+" following syntax for the link target: ``{filename}path/to/file``. Note: "
+"forward slashes, ``/``, are the required path separator in the "
+"``{filename}`` directive on all operating systems, including Windows."
+msgstr ""
+"要链接到站内(即在 ``content`` 目录下的文件),使用下述的目标链接语法: ``{filename}path/to/file`` "
+"。注意,在所有操作系统(当然也包括Windows)上,路径的分隔符都要使用正斜杠 ``/`` 。"
+
+#: ../../content.rst:246 dbd1404fa9fe47b7ba2594d1cc5d84f5
+msgid "For example, a Pelican project might be structured like this::"
+msgstr "例如,某Pelican项目的文件结构组织如下:"
+
+#: ../../content.rst:257 04b1728643124b6e903acb6c32d6c970
+msgid "In this example, ``article1.rst`` could look like this::"
+msgstr "在这个例子中, ``article1.rst`` 的内容如下:"
+
+#: ../../content.rst:269 9197b32aca1c4af6ac2f2b56e7498206
+msgid "and ``article2.md``::"
+msgstr "``article2.md`` 的内容如下:"
+
+#: ../../content.rst:280 baccc8dc58cd482cb42bd44d78d16d42
+msgid "Linking to static files"
+msgstr "链接到静态文件"
+
+#: ../../content.rst:282 33067c5bbb554baea7306b0c2f0b5356
+msgid ""
+"You can link to static content using ``{static}path/to/file``. Files "
+"linked to with this syntax will automatically be copied to the output "
+"directory, even if the source directories containing them are not "
+"included in the ``STATIC_PATHS`` setting of the project's "
+"``pelicanconf.py`` file."
+msgstr ""
+"您可以通过 ``{static}path/to/file`` 链接到静态内容。使用这个指令链接的文件都会被自动复制到输出目录中,即使它没有包含在 "
+"``STATIC_PATHS`` 中。"
+
+#: ../../content.rst:287 ../../content.rst:322 533a9aee68e5452db609cc5e1e569381
+#: 7c9993b8f8c44863975e5db9d5ce1cb8
+msgid "For example, a project's content directory might be structured like this::"
+msgstr "例如,某Pelican项目的文件结构组织如下:"
+
+#: ../../content.rst:297 7c70d916da684551b499f25fd9567e11
+msgid "``test.md`` would include::"
+msgstr "``test.md`` 的文件内容如下:"
+
+#: ../../content.rst:302 8921fb6dfbba4e6ea4c0220650617dc6
+msgid ""
+"Site generation would then copy ``han.jpg`` to ``output/images/han.jpg``,"
+" ``menu.pdf`` to ``output/pdfs/menu.pdf``, and write the appropriate "
+"links in ``test.md``."
+msgstr ""
+"站点生成时会将 ``han.jpg`` 拷贝到 ``output/images/han.jpg`` 、将 ``menu.pdf`` 拷贝到 "
+"``output/pdfs/menu.pdf`` ,同时也会自动把 ``test.md`` 中的相关链接都替换为正确的。"
+
+#: ../../content.rst:306 244c1bb923ec4b7ab33c039f2deefe94
+msgid ""
+"If you use ``{static}`` to link to an article or a page, this will be "
+"turned into a link to its source code."
+msgstr "如果您使用 ``{static}`` 链接到文章或页面,会链接到他们的源文件而不是渲染后的文章或页面。"
+
+#: ../../content.rst:310 50d69d50e26d4b48b4b1fb2643efa0e6
+msgid "Attaching static files"
+msgstr "将静态文件作为附件"
+
+#: ../../content.rst:312 f28e37fba55b49a99f03bbafc669ef87
+msgid ""
+"Starting with Pelican 3.5, static files can be \"attached\" to a page or "
+"article using this syntax for the link target: ``{attach}path/to/file``. "
+"This works like the ``{static}`` syntax, but also relocates the static "
+"file into the linking document's output directory. If the static file "
+"originates from a subdirectory beneath the linking document's source, "
+"that relationship will be preserved on output. Otherwise, it will become "
+"a sibling of the linking document."
+msgstr ""
+"从Pelican 3.5开始,静态文件可以使用下述语法 “附” 在页面或文章上: ``{attach}path/to/file`` 。这和 "
+"``{static}`` "
+"语法很像,也会将静态文件重定位到文章或页面的对应输出目录中。当推文所链接的静态文件处于其源文件所在位置的子目录下时,这种父子关系在输出目录中会得以保留。否则,默认情况下,静态文件会和对应的文档输出到同一目录层级下。"
+
+#: ../../content.rst:320 dba2dfdd8ef14b41b37f9db53ebb9704
+msgid "This only works for linking to static files."
+msgstr "这只在链接到静态文件时起作用。"
+
+#: ../../content.rst:333 a523bb1926b54025908733f0aca757c5
+msgid "``pelicanconf.py`` would include::"
+msgstr "例如对于某设置文件 ``pelicanconf.py`` "
+
+#: ../../content.rst:340 d12e170143234a51862ac73d04acb16b
+msgid "``testpost.md`` would include::"
+msgstr "``testpost.md`` 的内容如下:"
+
+#: ../../content.rst:350 8628f5e27e51444fad84dc68aa8a74bb
+msgid ""
+"Site generation would then produce an output directory structured like "
+"this::"
+msgstr "对应生成输出的站点目录结构如下:"
+
+#: ../../content.rst:360 8f74e3a043b84a088708bc046118b327
+msgid ""
+"Notice that all the files linked using ``{attach}`` ended up in or "
+"beneath the article's output directory."
+msgstr "可以注意到,使用 ``{attach}`` 链接的文件要么和文章输出处于同级目录,要么就是在文章所在位置的子目录下。"
+
+#: ../../content.rst:363 cdaf8ffc246645da8614e76072a6704d
+msgid ""
+"If a static file is linked multiple times, the relocating feature of "
+"``{attach}`` will only work in the first of those links to be processed. "
+"After the first link, Pelican will treat ``{attach}`` like ``{static}``. "
+"This avoids breaking the already-processed links."
+msgstr ""
+"若一个静态文件被多次链接, ``{attach}`` 只会在该静态文件第一次被链接时进行重定位处理(即按照上面的规则复制到对应目录)。之后使用 "
+"``{attach}`` 进行的链接的效果就和 ``{static}`` 一模一样了。这样子就可以避免破坏已经生成好的链接。"
+
+#: ../../content.rst:368 0783ef45de914a48af081fbf5978ae93
+msgid ""
+"**Be careful when linking to a file from multiple documents:** Since the "
+"first link to a file finalizes its location and Pelican does not define "
+"the order in which documents are processed, using ``{attach}`` on a file "
+"linked by multiple documents can cause its location to change from one "
+"site build to the next. (Whether this happens in practice will depend on "
+"the operating system, file system, version of Pelican, and documents "
+"being added, modified, or removed from the project.) Any external sites "
+"linking to the file's old location might then find their links broken. "
+"**It is therefore advisable to use {attach} only if you use it in all "
+"links to a file, and only if the linking documents share a single "
+"directory.** Under these conditions, the file's output location will not "
+"change in future builds. In cases where these precautions are not "
+"possible, consider using ``{static}`` links instead of ``{attach}``, and "
+"letting the file's location be determined by the project's "
+"``STATIC_SAVE_AS`` and ``STATIC_URL`` settings. (Per-file ``save_as`` and"
+" ``url`` overrides can still be set in ``EXTRA_PATH_METADATA``.)"
+msgstr ""
+"**当同一文件被多个推文链接时需要尤其小心:** "
+"第一次链接到文件时,Pelican就会确定其最终位置,而Pelican处理推文的顺序是不能确定的,因此多个推文使用 ``{attach}`` "
+"链接到同一文件时,每一次站点生成后该文件的最终位置是无法确定的(这种情况发生与否取决于操作系统、文件系统、Pelican的版本、推文从项目中的添加修改移除)。当这种情况发生时,其他站点到本站点文件旧位置的链接就会损坏。**因此,只有当静态文件只被一篇推文链接,或链接到某静态文件的推文都在同一目录下时才使用"
+" {attach}**。在这种情况下,该文件的输出位置在站点构建中不会变化。如果无法保证上述条件来预防链接损坏,可以考虑使用 "
+"``{static}`` 来替换 ``{attach}`` 。如此,文件的最终位置就由 ``STATIC_SAVE_AS`` 和 "
+"``STATIC_URL`` 来决定。(每个文件的 ``save_as`` 和 ``url`` 仍然可以通过更改 "
+"``EXTRA_PATH_METADATA`` 设置来覆盖)"
+
+#: ../../content.rst:385 85347094a7f741ac96f2489969660181
+msgid ""
+"When using ``{attach}``, any parent directory in ``*_URL`` / "
+"``*_SAVE_AS`` settings should match each other. See also: :ref:`url-"
+"settings`"
+msgstr ""
+"当使用{attach}时, ``*_URL`` / ``*_SAVE_AS`` 设置中的所有父目录都应该互相对应。具体请参见 "
+":ref:`URL配置` 。"
+
+#: ../../content.rst:389 eaefe7d009be4a5797cabee8bf1230a4
+msgid "Linking to authors, categories, index and tags"
+msgstr "链接到作者、分类、索引、标签"
+
+#: ../../content.rst:391 2c5b13a80a6b49acadeed0ff3d71236f
+msgid ""
+"You can link to authors, categories, index and tags using the "
+"``{author}name``, ``{category}foobar``, ``{index}`` and ``{tag}tagname`` "
+"syntax."
+msgstr ""
+"您可以通过 ``{author}name`` 、 ``{category}foobar`` 、 ``{index}`` 和 "
+"``{tag}tagname`` 这样的语法链接到作者、分类、索引和标签。"
+
+#: ../../content.rst:395 ec56f8d188bf4e41a961f00535b16dfb
+msgid "Deprecated internal link syntax"
+msgstr "已弃用的内部链接语法"
+
+#: ../../content.rst:397 01e39bc18c964baaaf43779b37fbaa01
+msgid ""
+"To remain compatible with earlier versions, Pelican still supports "
+"vertical bars (``||``) in addition to curly braces (``{}``) for internal "
+"links. For example: ``|filename|an_article.rst``, ``|tag|tagname``, "
+"``|category|foobar``. The syntax was changed from ``||`` to ``{}`` to "
+"avoid collision with Markdown extensions or reST directives. Similarly, "
+"Pelican also still supports linking to static content with "
+"``{filename}``. The syntax was changed to ``{static}`` to allow linking "
+"to both generated articles and pages and their static sources."
+msgstr ""
+"为了保持和早期版本的兼容,在内部链接中除了使用花括号( ``{}`` )外,还支持在内部链接中使用竖线( ``||`` )。例如, "
+"``|filename|an_article.rst`` 、 ``|tag|tagname`` 、 ``|category|foobar`` "
+"。将语法中的 ``||`` 改到 ``{}`` 是为了避免和Markdown或reST的语法和指令相冲突。类似地, ``{filename}`` "
+"虽然仍能使用,但是其语法已经改为了 ``{static}`` 。 ``{static}`` 既可以链接到文章或页面,也可以链接到静态资源。"
+
+#: ../../content.rst:405 375eca8f0c324943a3d5ba60f46e8aa7
+msgid "Support for the old syntax may eventually be removed."
+msgstr "对旧语法地支持最终会被移除。"
+
+#: ../../content.rst:408 d1e5719616d5454a810ed1562d0610fa
+msgid "Including other files"
+msgstr "引入其他文件"
+
+#: ../../content.rst:409 b429cad5b7904db5b16053bd9dbc7bb6
+msgid "Both Markdown and reStructuredText syntaxes provide mechanisms for this."
+msgstr "Markdown和reStructuredText的语法中都提供了这种机制"
+
+#: ../../content.rst:411 fa6e783b42c84147a18f2a23136a8212
+msgid ""
+"Following below are some examples for **reStructuredText** using `the "
+"include directive`_:"
+msgstr "下面是 **reStructuredText** 使用 `include指令`_ 的一些例子:"
+
+#: ../../content.rst:417 ecbaa72c1df64857b2e720ab7055e258
+msgid ""
+"Include a fragment of a file delimited by two identifiers, highlighted as"
+" C++ (slicing based on line numbers is also possible):"
+msgstr "下面的例子,引入了一段用一对标识符分隔的文件片段,并指定以C++语法进行高亮显示。(同样支持通过行号指定片段)"
+
+#: ../../content.rst:426 04bf027b52124b669b3b56ea50ac240d
+msgid ""
+"Include a raw HTML file (or an inline SVG) and put it directly into the "
+"output without any processing:"
+msgstr "将一HTML文件(或者一个行内SVG)直接引入,并且不进行任何处理直接将其作为输出:"
+
+#: ../../content.rst:433 612365f02c5a471295f2f3601f0d95e9
+msgid ""
+"For **Markdown**, one must rely on an extension. For example, using the "
+"`mdx_include plugin`_:"
+msgstr "对于 **Markdown** ,若要进行文件引入,就必须使用扩展插件。例如可以使用 `mdx_include plugin`_ :"
+
+#: ../../content.rst:443 30c87f2b5e594c24ac8ab719614c71fd
+msgid "Importing an existing site"
+msgstr "导入已有站点"
+
+#: ../../content.rst:445 f0f0ccd87dcc4afebe9b7d954481eeb2
+msgid ""
+"It is possible to import your site from several other blogging sites "
+"(like WordPress, Tumblr, ..) using a simple script. See :ref:`import`."
+msgstr "您可以使用一个简单的脚本导入已有的站点(例如WordPress、Tumblr)。详见 :ref:`导入已有站点` 。"
+
+#: ../../content.rst:449 48de7111f6ec49ec8637c06e7d774f26
+msgid "Translations"
+msgstr "翻译"
+
+#: ../../content.rst:451 0d1f7e6d14b746e2bb40f200c23f89a5
+msgid ""
+"It is possible to translate articles. To do so, you need to add a "
+"``lang`` meta attribute to your articles/pages and set a ``DEFAULT_LANG``"
+" setting (which is English [en] by default). With those settings in "
+"place, only articles with the default language will be listed, and each "
+"article will be accompanied by a list of available translations for that "
+"article."
+msgstr ""
+"一篇文章可以有多个翻译版本。对于这类文章,您需要加上元数据属性 ``lang`` ,并且配置 ``DEFAULT_LANG`` "
+"(默认为[en])。完成上述配置后,文章列表中列出的是默认语言版本的文章,文章内容页中会列出所有可用的翻译版本供读者选择。"
+
+#: ../../content.rst:459 61df3a34ac194a2eb037c1b4e868265c
+msgid ""
+"This core Pelican functionality does not create sub-sites (e.g. "
+"``example.com/de``) with translated templates for each language. For such"
+" advanced functionality the `i18n_subsites plugin`_ can be used."
+msgstr ""
+"Pelican的这个核心功能并不会给同一文章的不同语言版本创建子站点(例如 ``example.com/de`` "
+")。但是如果需要创建子站点的话,可以使用扩展插件 `i18n_subsites plugin`_ 。"
+
+#: ../../content.rst:464 c05ed4b06cec45248f976be0580b257c
+msgid ""
+"By default, Pelican uses the article's URL \"slug\" to determine if two "
+"or more articles are translations of one another. (This can be changed "
+"with the ``ARTICLE_TRANSLATION_ID`` setting.) The slug can be set "
+"manually in the file's metadata; if not set explicitly, Pelican will "
+"auto-generate the slug from the title of the article."
+msgstr ""
+"默认情况下,Pelican会使用文章的URL “slug” 来判断当前文档是否是同一篇文章的不同翻译版本。(这一点可以通过配置 "
+"``ARTICLE_TRANSLATION_ID`` "
+"来改变)slug可以通过元数据手动指定,若没有,Pelican会根据文章的标题(title)来自动生成slug。"
+
+#: ../../content.rst:470 e448fdfd15c046fb8c641fcead12b26d
+msgid ""
+"Here is an example of two articles, one in English and the other in "
+"French."
+msgstr "以下的例子是一篇文章有英语和法语两个翻译版本的情况。"
+
+#: ../../content.rst:472 62a186c5d6194a37b884343a858f2200
+msgid "The English article::"
+msgstr "英语文章如下:"
+
+#: ../../content.rst:482 b32c5433696e4a09adb804cef323b3f1
+msgid "And the French version::"
+msgstr "法语版本为:"
+
+#: ../../content.rst:492 b4d1d69ebe22462d985ebe2cfc8cd1e8
+msgid ""
+"Post content quality notwithstanding, you can see that only item in "
+"common between the two articles is the slug, which is functioning here as"
+" an identifier. If you'd rather not explicitly define the slug this way, "
+"you must then instead ensure that the translated article titles are "
+"identical, since the slug will be auto-generated from the article title."
+msgstr "值得注意的是,以上两篇文章的slug是相同的,即slug作为唯一标识符存在。若您没有手动指定slug,那么请保证同一篇文章的不同翻译版本的标题是相同的。如此,由于slug会根据文章标题自动生成,它们隐含的slug会是相同的。"
+
+#: ../../content.rst:498 2e50d70746634009a070dc41068fbc89
+msgid ""
+"If you do not want the original version of one specific article to be "
+"detected by the ``DEFAULT_LANG`` setting, use the ``translation`` "
+"metadata to specify which posts are translations::"
+msgstr ""
+"如果您不希望某篇文章的原始版本以 ``DEFAULT_LANG`` 翻译版本出现,可以使用 ``translation`` "
+"元数据来指出本推文是一个非默认语言的翻译版本。(译者注:例如,设置的默认语言为zh_CN,如果某篇推文的原始版本是英文而不是中文,那么对于中文翻译版本的就可以指定其translations元数据为true,即对于该推文来说,中文版本是翻译后的版本)"
+
+#: ../../content.rst:515 01ecf34fd1e440ea908fd181001b38b6
+msgid "Syntax highlighting"
+msgstr "语法高亮"
+
+#: ../../content.rst:517 4d7eebd1886347b383ea3b1c517b821d
+msgid ""
+"Pelican can provide colorized syntax highlighting for your code blocks. "
+"To do so, you must use the following conventions inside your content "
+"files."
+msgstr "您可以按照下面的约定在文件内容中添加代码块,Pelican可以完成五彩缤纷的语法高亮。"
+
+#: ../../content.rst:520 5896f772fcd04f309e2188040f0bea60
+msgid ""
+"For reStructuredText, use the ``code-block`` directive to specify the "
+"type of code to be highlighted (in these examples, we'll use "
+"``python``)::"
+msgstr "对于reStructuredText,使用 ``code-block`` 指令指定代码所使用的语言(此处以``python``为例):"
+
+#: ../../content.rst:527 ec6ec4c325c6406ba3b00437116b84b8
+msgid ""
+"For Markdown, which utilizes the `CodeHilite extension`_ to provide "
+"syntax highlighting, include the language identifier just above the code "
+"block, indenting both the identifier and the code::"
+msgstr "Markdown则使用 `CodeHilite extension`_ 扩展插件来完成语法高亮。在代码上方标记所用语言,同时将其与代码都进行缩进:"
+
+#: ../../content.rst:541 58220db84e4d4ab7950dad7ad36ea1b5
+msgid ""
+"The specified identifier (e.g. ``python``, ``ruby``) should be one that "
+"appears on the `list of available lexers "
+"`_."
+msgstr ""
+"指定语言的标识符(例如 ``python``、``ruby``)必须是在 `可用列表 "
+"`_ 中列出的。"
+
+#: ../../content.rst:544 cb10d4bc6f4c44008ce8324df993c2ed
+msgid ""
+"When using reStructuredText the following options are available in the "
+"`code-block` directive:"
+msgstr "对于reStructuredText,下面列出的选项可以在 `code-block` 命令中使用:"
+
+#: ../../content.rst:548 3598816f6ab54705aa545de3eb95a22c
+msgid "Option"
+msgstr "选项"
+
+#: ../../content.rst:548 2861fb4a308a443c971110b5757e9d13
+msgid "Valid values"
+msgstr "有效值"
+
+#: ../../content.rst:550 638a4299a7d346659254d7aa6e2485e7
+msgid "anchorlinenos"
+msgstr "anchorlinenos"
+
+#: ../../content.rst:550 ../../content.rst:574 ../../content.rst:576
+#: 0e32384143484934af18e224e414a45b 217edf5016f74e23a906623d077191ff
+#: c6b0e9c5aa4340329b2fe203222055df
+msgid "N/A"
+msgstr "N/A"
+
+#: ../../content.rst:550 e219ff4135fb45e8b27fdd71a874ffee
+msgid "If present, wrap line numbers in ```` tags."
+msgstr "指定行号是否显示在 标签中"
+
+#: ../../content.rst:551 8e95919e90e14208a8150c2c52cb20b9
+msgid "classprefix"
+msgstr "classprefix"
+
+#: ../../content.rst:551 ../../content.rst:559 ../../content.rst:561
+#: ../../content.rst:570 ../../content.rst:572 ../../content.rst:577
+#: ../../content.rst:578 96789c1cd92545b1a9153e9be1c5726d
+#: 9e591c65044b4ca4aa876e0dd5ba94bc a1920b40389d4b25a66cb0e755389960
+#: bee284b2086a40a4aa28bc87c916d9df cb11442c371b48349bba579e7dfce72b
+#: e330b50a8cea43a5b55771f04fc4e688 f28e8d5bd9544ccbbcb99037c02f08cf
+msgid "string"
+msgstr "string"
+
+#: ../../content.rst:551 f6d85a8a8ec74c46a313bcfb72f5283a
+msgid "String to prepend to token class names"
+msgstr "要添加到用于语法高亮的css类名前面的字符串"
+
+#: ../../content.rst:552 4fd6cd04ea444c389c6f77030eb0a123
+msgid "hl_lines"
+msgstr "hl_lines"
+
+#: ../../content.rst:552 aa5112c2c73e40d9940b5a21eaa1d650
+msgid "numbers"
+msgstr "numbers"
+
+#: ../../content.rst:552 1b03b3add35c44eeaef4d3c31dd51fb4
+msgid ""
+"List of lines to be highlighted, where line numbers to highlight are "
+"separated by a space. This is similar to ``emphasize-lines`` in Sphinx, "
+"but it does not support a range of line numbers separated by a hyphen, or"
+" comma-separated line numbers."
+msgstr "需要高亮的行号列表,行号之间以空格隔开。这与Sphinx中的 ``emphasize-lines`` 类似,但是不支持使用连字符和逗号指定行号范围。"
+
+#: ../../content.rst:559 abe7266edc704a0b857856e92fd2022b
+msgid "lineanchors"
+msgstr "lineanchors"
+
+#: ../../content.rst:559 baa7634eb7e646e39698c24bc3ee82af
+msgid "Wrap each line in an anchor using this string and -linenumber."
+msgstr "用此处指定的字符串和 “-行号”给每一行都加上锚点。"
+
+#: ../../content.rst:561 21ccf81937cf4fe38f556f2852524269
+msgid "linenos"
+msgstr "linenos"
+
+#: ../../content.rst:561 2b1b4a9f23e448d4baaf5d36b896a5ba
+msgid ""
+"If present or set to \"table\", output line numbers in a table; if set to"
+" \"inline\", output them inline. \"none\" means do not output the line "
+"numbers for this table."
+msgstr "开启此选项或将此选项设为“table”时,输出表格时会带上行号;如果设为“inline”,则内联输出行号;如果设为“none”,则不输出行号。"
+
+#: ../../content.rst:566 d9813ccee6d24eae8c539fd9cc0ddd54
+msgid "linenospecial"
+msgstr "linenospecial"
+
+#: ../../content.rst:566 ../../content.rst:568 ../../content.rst:569
+#: 1eeb1f08e07e4f95a03cbeca48b422a6 bac61cf96bc3466985c9f4d5b934055b
+#: eadc4e3c92094e589c3b931d20cd97ab
+msgid "number"
+msgstr "number"
+
+#: ../../content.rst:566 ff3b3aa5e45e4a3a837400e8333f7c5a
+msgid "If set, every nth line will be given the 'special' CSS class."
+msgstr "是否每隔几行就设置一行特殊的css样式类。"
+
+#: ../../content.rst:568 e32730e901bb460e975410fe26a9432f
+msgid "linenostart"
+msgstr "linenostart"
+
+#: ../../content.rst:568 48d2621a74174b82a71d52a921e2f60f
+msgid "Line number for the first line."
+msgstr "起始行的行号。"
+
+#: ../../content.rst:569 fcb4c1088bb04cd9ba6e4273e3013369
+msgid "linenostep"
+msgstr "linenostep"
+
+#: ../../content.rst:569 1ce5e05481f84c7f84964bb1d2e3e9ae
+msgid "Print every nth line number."
+msgstr "每隔几行输出一次"
+
+#: ../../content.rst:570 110dc8da76774b3ca517ad93c53fbd3f
+msgid "lineseparator"
+msgstr "lineseparator"
+
+#: ../../content.rst:570 b9ba8609393c4ec8b964481ae2c66614
+msgid "String to print between lines of code, '\\n' by default."
+msgstr "每行输出代码之间的输出字符串,默认为 '\\n'。"
+
+#: ../../content.rst:572 8b336c4c8e65427ebb1a89e94232199a
+msgid "linespans"
+msgstr "linespans"
+
+#: ../../content.rst:572 07c2d6ca97084859b47b09237633a4ab
+msgid "Wrap each line in a span using this and -linenumber."
+msgstr "使用指定的字符串和“-行号”将每一行包装在一个span中。"
+
+#: ../../content.rst:574 bd0c5e4ba73d458aa14fce20c1347910
+msgid "nobackground"
+msgstr "nobackground"
+
+#: ../../content.rst:574 07672d498e2f4b6e8d4da4b5382a34f0
+msgid "If set, do not output background color for the wrapping element"
+msgstr "若设置,则不为元素输出背景颜色"
+
+#: ../../content.rst:576 a054798a57814cfd9b363d7048dd9e1e
+msgid "nowrap"
+msgstr "nowrap"
+
+#: ../../content.rst:576 de085518cf324de4b6d917c616e2b7dd
+msgid "If set, do not wrap the tokens at all."
+msgstr "若设置,则不对token进行换行处理。"
+
+#: ../../content.rst:577 5989452c45bd4cc187e1cd1cfb88b440
+msgid "tagsfile"
+msgstr "tagsfile"
+
+#: ../../content.rst:577 74b9388dcbe048ff824108bafc0bf72b
+msgid "ctags file to use for name definitions."
+msgstr "用于命名定义的ctags文件"
+
+#: ../../content.rst:578 0b355baf272c4e87a18b1594b311258f
+msgid "tagurlformat"
+msgstr "tagurlformat"
+
+#: ../../content.rst:578 dde5f2fd922b4b45b5eca083527dd93a
+msgid "format for the ctag links."
+msgstr "用于ctag链接的格式"
+
+#: ../../content.rst:581 e034ff3a3ee44ef185f8c3aed60fc692
+msgid ""
+"Note that, depending on the version, your Pygments module might not have "
+"all of these options available. Refer to the *HtmlFormatter* section of "
+"the `Pygments documentation `_ for"
+" more details on each of the options."
+msgstr ""
+"请注意,由于版本的不同,Pygments模块可能不完全支持上述选项。请参考 `Pygments文档 "
+"`_ 中 *HtmlFormatter* "
+"一节获取每个选项的详细信息。"
+
+#: ../../content.rst:586 e7df88ffb2d4475ca19259b222d1ab3e
+msgid ""
+"For example, the following code block enables line numbers, starting at "
+"153, and prefixes the Pygments CSS classes with *pgcss* to make the names"
+" more unique and avoid possible CSS conflicts::"
+msgstr ""
+"举个例子,下面的代码块开启了行号显示,从153行开始输出,并且指定Pygments的CSS类以 *pgcss* "
+"为前缀,使得类名更为独特并避免可能的CSS冲突:"
+
+#: ../../content.rst:597 fc9b8b1fa7364ce1a274281a8e2e7237
+msgid ""
+"It is also possible to specify the ``PYGMENTS_RST_OPTIONS`` variable in "
+"your Pelican settings file to include options that will be automatically "
+"applied to every code block."
+msgstr ""
+"您也可以在Pelican的配置文件中指定 ``PYGMENTS_RST_OPTIONS`` "
+",如此就可以让Pelican自动在每个代码块上使用指定的选项。"
+
+#: ../../content.rst:601 b51dfbadd3bc42a483611d7013a87241
+msgid ""
+"For example, if you want to have line numbers displayed for every code "
+"block and a CSS prefix, you would set this variable to::"
+msgstr ""
+"举个例子,若您希望每个代码块都显示行号,并且在CSS类名前都加上前缀pgcss,就可以像这样设置 ``PYGMENTS_RST_OPTIONS``"
+" :"
+
+#: ../../content.rst:606 82a9f33cc7c9493e8d8772f6c6fb63da
+msgid ""
+"If specified, settings for individual code blocks will override the "
+"defaults in your settings file."
+msgstr ""
+"若指定了 ``PYGMENTS_RST_OPTIONS`` ,同时也为代码块单独指定了一些选项,单独指定的会将 "
+"``PYGMENTS_RST_OPTIONS`` 覆盖。"
+
+#: ../../content.rst:610 d2baf0b12ba148f0af9ccab86542e35f
+msgid "Publishing drafts"
+msgstr "发布草稿"
+
+#: ../../content.rst:612 2ba53426b76742e6980e6700c94d3d96
+msgid ""
+"If you want to publish an article or a page as a draft (for friends to "
+"review before publishing, for example), you can add a ``Status: draft`` "
+"attribute to its metadata. That article will then be output to the "
+"``drafts`` folder and not listed on the index page nor on any category or"
+" tag page."
+msgstr ""
+"如果您想要以草稿的形式发布文章或页面(例如在正式发布前给朋友预览),可以添加元数据属性 ``Status: draft`` 。如此,文章就会输出到"
+" ``drafts`` 文件夹中,并且不会被列在首页、分类或是标签页面中。"
+
+#: ../../content.rst:617 e3a756e1580d48378a16946caeb79c8a
+msgid ""
+"If your articles should be automatically published as a draft (to not "
+"accidentally publish an article before it is finished), include the "
+"status in the ``DEFAULT_METADATA``::"
+msgstr ""
+"若您希望文章默认以草稿形式发布(可以防止在完成文章前不小心将其正式发布),可以将此status属性加在 ``DEFAULT_METADATA`` "
+"中:"
+
+#: ../../content.rst:625 c4b74b80b8714eb2a69d81f42f6e3e27
+msgid ""
+"To publish a post when the default status is ``draft``, update the post's"
+" metadata to include ``Status: published``."
+msgstr "要发布当前处于 ``draft`` 状态的推文,更新推文的元数据,使其中包括 ``Status: published``。"
+
+#: ../../content.rst:629 f8baadb48b12467aaa1025f018ab6621
+msgid "Hidden Posts"
+msgstr "隐藏推文"
+
+#: ../../content.rst:631 eb5efca86b2d4432a49703306334591a
+msgid ""
+"Like pages, posts can also be marked as ``hidden`` with the ``Status: "
+"hidden`` attribute. Hidden posts will be output to ``ARTICLE_SAVE_AS`` as"
+" expected, but are not included by default in tag, category, and author "
+"indexes, nor in the main article feed. This has the effect of creating an"
+" \"unlisted\" post."
+msgstr ""
+"和页面一样,推文也能通过 ``Status: hidden`` 标记为隐藏状态。隐藏的推文会输出到 ``ARTICLE_SAVE_AS`` "
+"指定的目录中,这些推文“不会被列出”,即不会在标签、分类、作者主页、feed中出现。"
+
+#: ../../content.rst:637 2d67772b24bb40748d56dc3938195ce6
+msgid "Skip Posts"
+msgstr "忽略推文"
+
+#: ../../content.rst:639 0c97c429a7a74ba4830851491829d63e
+msgid ""
+"Posts marked with ``skip`` status are ignored entirely. They are not "
+"processed nor output to the ``ARTICLE_SAVE_AS`` path. Such posts will "
+"similarly not be included in indexes or feeds."
+msgstr ""
+"状态设为了 ``skip`` 的推文将会被完全忽略。也就是说,他们不会被处理,也不会输出到 ``ARTICLE_SAVE_AS`` "
+"指定的目录中。同样,被忽略的推文不会出现在索引或者订阅源中。"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/contribute.po b/docs/locale/zh_CN/LC_MESSAGES/contribute.po
new file mode 100644
index 00000000..3149fff3
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/contribute.po
@@ -0,0 +1,731 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-25 20:36+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../contribute.rst:2 e8f9694c47aa44e7944dae800ee528f3
+msgid "Contributing and feedback guidelines"
+msgstr "项目贡献与意见反馈"
+
+#: ../../contribute.rst:4 784f37182e78474b960306a5a794ae16
+msgid ""
+"There are many ways to contribute to Pelican. You can improve the "
+"documentation, add missing features, and fix bugs (or just report them). "
+"You can also help out by reviewing and commenting on `existing issues "
+"`_."
+msgstr ""
+"有很多渠道可以参与到贡献项目中来,例如帮助改进文档、添加缺失的特性、修复与报告bug。"
+"可以从查看 `已有 issues `_ 开始。"
+
+#: ../../contribute.rst:9 e17c3ff0fa71469cbe22cb4ad2640ad8
+msgid ""
+"Don't hesitate to fork Pelican and submit an issue or pull request on "
+"GitHub. When doing so, please consider the following guidelines."
+msgstr ""
+"随时随地都可以fork Pelican或是在GitHub上提交issue或PR。"
+
+#: ../../../CONTRIBUTING.rst:2 f8bc69070fab4dd7be34e1cc6a42cc02
+msgid "Filing issues"
+msgstr "提出issue"
+
+#: ../../../CONTRIBUTING.rst:4 fe98a059b9c24fcc92358f2c4505174d
+msgid "Before you submit a new issue, try `asking for help`_ first."
+msgstr "在你提交一个新的issue之前,可以先尝试 `请求他人帮助`_ 。"
+
+#: ../../../CONTRIBUTING.rst:5 e9fff7c354614ae28db994c0fcc121c0
+msgid ""
+"If determined to create a new issue, first search `Pelican Discussions`_ "
+"and `existing issues`_ (open and closed) to see if your question has "
+"already been answered previously."
+msgstr ""
+"当你决定要提出新的issue时,先在 `Pelican的讨论版`_ 和 `已有issues`_ 中搜索一下,"
+"(开放关闭的issue都搜一下),来看看你的问题是不是有人之前已经提出过。"
+
+#: ../../../CONTRIBUTING.rst:14 84cb74beed564f31810674cacf5c1f97
+msgid "How to get help"
+msgstr "如何获取帮助"
+
+#: ../../../CONTRIBUTING.rst:16 0557a84947c14606be4fd0565247d85d
+msgid "Before you ask for help, please make sure you do the following:"
+msgstr "在寻求帮助之前,请先尝试如下步骤:"
+
+#: ../../../CONTRIBUTING.rst:18 6d59a3356e734dd196ec8a0739556b4c
+msgid ""
+"Read the documentation_ thoroughly. If in a hurry, at least use the "
+"search field that is provided at top-left on the documentation_ pages. "
+"Make sure you read the docs for the Pelican version you are using."
+msgstr ""
+"完整阅读 documentation_ 。如果你很急,至少先在 documentation_ 左上角的搜索栏"
+"中尝试搜索。确保你阅读的文档和使用的Pelican版本相匹配。"
+
+#: ../../../CONTRIBUTING.rst:21 4b33299936404cf98a66b672fad0e38f
+msgid ""
+"Use a search engine (e.g., DuckDuckGo, Google) to search for a solution "
+"to your problem. Someone may have already found a solution, perhaps in "
+"the form of a ':pelican-doc:`plugins` or a specific combination of "
+"settings."
+msgstr ""
+"使用搜索引擎(例如 DuckDuckGo、Google)搜索遇到问题的解决方案。互联网上可能"
+"已经有人遇到过相同的问题,解决方法可能包括使用某些 :pelican-doc:`plugins` 或配置"
+"一系列的设置选项。"
+
+#: ../../../CONTRIBUTING.rst:25 b48195d9ef674566b89aabc38139c301
+msgid "Try reproducing the issue in a clean environment, ensuring you are using:"
+msgstr "尝试在一个尽可能简单的环境中重现问题,并确保以下几点:"
+
+#: ../../../CONTRIBUTING.rst:27 685d2888d2c94ea9a752ec433f8b9f1f
+msgid ""
+"latest Pelican release (or an up-to-date Git clone of Pelican ``main`` "
+"branch)"
+msgstr "使用最新版本的Pelican(或是用Git克隆Pelican的main分支)"
+
+#: ../../../CONTRIBUTING.rst:28 910a372d95d8448492eafc66eccd1ccf
+msgid "latest releases of libraries used by Pelican"
+msgstr "将Pelican使用的库升级到最新版本"
+
+#: ../../../CONTRIBUTING.rst:29 c44f4dc6b05d4be29eccc889f042702c
+msgid "no plugins or only those related to the issue"
+msgstr "此环境中没有使用插件或是只使用和问题相关的插件"
+
+#: ../../../CONTRIBUTING.rst:31 3abdf6131cf4412a8205b634a6651b01
+msgid ""
+"**NOTE:** The most common sources of problems are anomalies in (1) "
+"themes, (2) plugins, (3) settings files, and (4) ``make``/``invoke`` "
+"automation wrappers. If you can't reproduce your problem when using the "
+"following steps to generate your site, then the problem is almost "
+"certainly with one of the above-listed elements (and not Pelican "
+"itself)::"
+msgstr ""
+"**注意:** 最常见的问题基本上都产生于主题、插件、设置文件和自动化工具 "
+"``make``/``invoke`` 中。如果按照下述步骤生成站点后无法复现之前的问题,那么"
+"几乎可以肯定问题出在这四个地方,而不在Pelican本身:"
+
+#: ../../../CONTRIBUTING.rst:41 f2331ea165ac4a3c8e70bf98c995f0e8
+msgid ""
+"If you can generate your site without problems using the steps above, "
+"then your problem is unlikely to be caused by Pelican itself, and "
+"therefore please consider reaching out to the maintainers of the "
+"plugins/theme you are using instead of raising the topic with the Pelican"
+" core community."
+msgstr ""
+"如果按照上述步骤能够正常生成站点,那么你的问题不太可能是由Pelican本身导致的,"
+"请考虑联系对应插件/主题的维护者,而不是在Pelican内核的社区中提出问题。"
+
+#: ../../../CONTRIBUTING.rst:46 d83b0036d4894f3ebc73e657a203d11a
+msgid ""
+"If despite the above efforts you still cannot resolve your problem, be "
+"sure to include in your inquiry the following information, preferably in "
+"the form of links to content uploaded to a `paste service`_, GitHub "
+"repository, or other publicly-accessible location:"
+msgstr ""
+"经过上面这些努力,若您仍无法解决问题,确保你的提问中包括如下信息,可以以 "
+"`paste service`_ 链接、GitHub仓库,或者其他可公开获取的形式提供:"
+
+#: ../../../CONTRIBUTING.rst:51 4281f931e9064336b267bd67a35134e9
+msgid ""
+"Describe what version of Pelican you are running (output of ``pelican "
+"--version`` or the HEAD commit hash if you cloned the repo) and how "
+"exactly you installed it (the full command you used, e.g. ``python -m pip"
+" install pelican``)."
+msgstr ""
+"描述正在运行的Pelican版本信息(可以通过 ``pelican --version`` 命令得到,如果"
+"clone的源仓库则可以查看HEAD commit的哈希值),以及你是如何安装Pelican的"
+"(要包括使用到的命令,例如 ``python -m pip install pelican``)"
+
+#: ../../../CONTRIBUTING.rst:54 b1303c98bca840efb895aceb16789eb9
+msgid ""
+"If you are looking for a way to get some end result, prepare a detailed "
+"description of what the end result should look like (preferably in the "
+"form of an image or a mock-up page) and explain in detail what you have "
+"done so far to achieve it."
+msgstr ""
+"如果你希望产生某种特定的最终结果,请详细描述此最终结果是什么样的(最好以图片或者"
+"伪页面的形式),,并且细致讲述你做了哪些尝试。"
+
+#: ../../../CONTRIBUTING.rst:58 8fe972c4685140d5bd1c37f4635f6f09
+msgid ""
+"If you are trying to solve some issue, prepare a detailed description of "
+"how to reproduce the problem. If the issue cannot be easily reproduced, "
+"it cannot be debugged by developers or volunteers. Describe only the "
+"**minimum steps** necessary to reproduce it (no extra plugins, etc.)."
+msgstr ""
+"如果你在尝试解决某些问题,请详细描述如何复现此问题。如果问题很难被复现,其他开发者和志愿者就很难进行调试。"
+"尽量只写出复现该问题的 **最少步骤** (无额外插件)。"
+
+#: ../../../CONTRIBUTING.rst:62 1f3874f308e64281b910dc716180ebcf
+msgid ""
+"Upload your settings file or any other custom code that would enable "
+"people to reproduce the problem or to see what you have already tried to "
+"achieve the desired end result."
+msgstr ""
+"上传你的配置文件以及所有自定义过的代码,这可以使得大家能够重现问题或者看到你已经"
+"做出的尝试。"
+
+#: ../../../CONTRIBUTING.rst:65 1fdc6c63f1b141c7a35233607ec0d922
+msgid ""
+"Upload detailed and **complete** output logs and backtraces (remember to "
+"add the ``--debug`` flag: ``pelican --debug content [...]``)"
+msgstr ""
+"上传详细 **完整** 的输出日志以及backtraces信息(记得在执行pelican命令时加上 "
+"``--debug`` 标记: ``pelican --debug content [...]`` )"
+
+#: ../../../CONTRIBUTING.rst:71 8741dba5da1a4990ae9c30531d05dc19
+msgid ""
+"Once the above preparation is ready, you can post your query as a new "
+"thread in `Pelican Discussions`_. Remember to include all the information"
+" you prepared."
+msgstr ""
+"一旦做好了上述准备,就可以在 `Pelican Discussions`_ 中发起你的问题了。记得在请求"
+"中附上收集好的信息。"
+
+#: ../../../CONTRIBUTING.rst:75 b34a3031f5d1427e92a9d1969d7b5274
+msgid "Contributing code"
+msgstr "贡献代码"
+
+#: ../../../CONTRIBUTING.rst:77 e29672c736554ebbbd6efd441af19df7
+msgid ""
+"Before you submit a contribution, please ask whether it is desired so "
+"that you don't spend a lot of time working on something that would be "
+"rejected for a known reason. Consider also whether your new feature might"
+" be better suited as a ':pelican-doc:`plugins` — you can `ask for help`_"
+" to make that determination."
+msgstr ""
+"在提交代码修改前,请先询问是否需要此修改,以免你做的工作因为已知原因而被拒绝。"
+"想想要添加的新特性是否更适合以 :pelican-doc:`插件` 形式完成。可以通过 "
+"`如何获取帮助`_ 来帮助你作出决定。"
+
+#: ../../../CONTRIBUTING.rst:82 e263c09fb6e5471eb0c2c3e97994322d
+msgid ""
+"Also, if you intend to submit a pull request to address something for "
+"which there is no existing issue, there is no need to create a new issue "
+"and then immediately submit a pull request that closes it. You can submit"
+" the pull request by itself."
+msgstr ""
+"另外,如果你的PR是为了解决一个目前没有在issue中出现过的问题,那么就没有必要先创建"
+"一个新的issue,而是可以直接提起PR。"
+
+#: ../../../CONTRIBUTING.rst:87 9b08ef3e5fe4474e9306e4bfe9662fff
+msgid "Using Git and GitHub"
+msgstr "使用Git与GitHub"
+
+#: ../../../CONTRIBUTING.rst:89 7ad95f82b7d04c0ca97bb958d2425e27
+msgid ""
+"`Create a new branch`_ specific to your change (as opposed to making your"
+" commits in the ``main`` branch)."
+msgstr ""
+"`创建一个新的分支`_ 来标记你做的修改(而不是直接在主分支中提交)。"
+
+#: ../../../CONTRIBUTING.rst:91 8a31c5d7ae4045cdbf2aa67e79be3f9c
+msgid ""
+"**Don't put multiple unrelated fixes/features in the same branch / pull "
+"request.** For example, if you're working on a new feature and find a "
+"bugfix that doesn't *require* your new feature, **make a new distinct "
+"branch and pull request** for the bugfix. Similarly, any proposed changes"
+" to code style formatting should be in a completely separate pull "
+"request."
+msgstr ""
+"**不要把多个无关联的修复/特性修改放在同一个分支/拉去请求中。** 如果当你在做新特性的时候"
+"发现了一个bug可以修复,但修复这个bug *不需要用到* 这个新特性, **那么请另外创建"
+"一个分支并拉取请求。** 类似的,任何对代码风格的格式化都应该在单独的请求中拉取。"
+
+#: ../../../CONTRIBUTING.rst:96 ef2e10f7ec5e4fbbb0f977dd09b7be49
+msgid ""
+"Add a ``RELEASE.md`` file in the root of the project that contains the "
+"release type (major, minor, patch) and a summary of the changes that will"
+" be used as the release changelog entry. For example::"
+msgstr ""
+"在项目根目录下添加 ``RELEASE.md`` 文件,在其中包含release的类型(主要、次要、补丁),"
+"以及对项目改变的概述,这些内容会作为该release发布日志的一部分。下面是一个例子:"
+
+#: ../../../CONTRIBUTING.rst:104 24a4d63624f44f63a0ce809901455c02
+msgid ""
+"Check for unnecessary whitespace via ``git diff --check`` before "
+"committing."
+msgstr ""
+"在提交前使用 ``git diff --check`` 来检查是否有无意义的空白字符。"
+
+#: ../../../CONTRIBUTING.rst:105 11c5b82604fe4638bf9ee6e9ef0a401b
+msgid ""
+"First line of your commit message should start with present-tense verb, "
+"be 50 characters or less, and include the relevant issue number(s) if "
+"applicable. *Example:* ``Ensure proper PLUGIN_PATH behavior. Refs #428.``"
+" If the commit *completely fixes* an existing bug report, please use "
+"``Fixes #585`` or ``Fix #585`` syntax (so the relevant issue is "
+"automatically closed upon PR merge)."
+msgstr ""
+"commit信息的第一行应该以现在时动词开头,并且第一行尽量保持在50字以下,并且包含相关联"
+"issue的编号(如果有的话)。 例如: ``Ensure proper PLUGIN_PATH behavior. "
+"Refs #428.`` 如果此项提交 *完全修复* 了某项已报告的bug,请使用例如 ``Fixes #585`` "
+"或 ``Fix #585`` 的语法(这样的话相关的issue会在PR合并后自动关闭)。"
+
+#: ../../../CONTRIBUTING.rst:110 0c1ff9d0738440e1bce853fc830278af
+msgid ""
+"After the first line of the commit message, add a blank line and then a "
+"more detailed explanation (when relevant)."
+msgstr ""
+"在第一行commit信息后添加一行空白行,再进行更多相关的细节描述。"
+
+#: ../../../CONTRIBUTING.rst:112 d817ad5d9e35488eb45d88828ee9f053
+msgid ""
+"`Squash your commits`_ to eliminate merge commits and ensure a clean and "
+"readable commit history."
+msgstr ""
+"`压缩commit`_ 来消除合并commits,确保你的commit历史记录是干净可读的。"
+
+#: ../../../CONTRIBUTING.rst:114 b7064f44923a499da3c3ce078470e269
+msgid ""
+"After you have issued a pull request, the continuous integration (CI) "
+"system will run the test suite on all supported Python versions and check"
+" for code style compliance. If any of these checks fail, you should fix "
+"them. (If tests fail on the CI system but seem to pass locally, ensure "
+"that local test runs aren't skipping any tests.)"
+msgstr ""
+"在你发出PR后,持续集成(CI)系统会在所有支持的Python版本上运行测试套件,并且"
+"检查代码风格的合规性。如果出现了错误,你应该将其修复。(如果没有通过CI系统上的"
+"测试但是本地测试通过了,请再检查一下,确保在本地进行了所有CI系统中的检查)"
+
+#: ../../../CONTRIBUTING.rst:121 342f2e6c14b9441caaf3f9b6d2eb764b
+msgid "Contribution quality standards"
+msgstr "贡献的质量标准"
+
+#: ../../../CONTRIBUTING.rst:123 842514f115634a5d821d48490d4aed7b
+msgid ""
+"Adhere to the project's code style standards. See: `Development "
+"Environment`_"
+msgstr ""
+"遵循项目的代码风格标准。详见 `开发环境`_"
+
+#: ../../../CONTRIBUTING.rst:124 4719590d89be4a5e94817902cc424be5
+msgid ""
+"Ensure your code is compatible with the `officially-supported Python "
+"releases`_."
+msgstr ""
+"确保你的代码可以兼容 `python的官方发布版本`_"
+
+#: ../../../CONTRIBUTING.rst:125 fa0ad5dd93e149fa8a12dd339bef9056
+msgid ""
+"Add docs and tests for your changes. Undocumented and untested features "
+"will not be accepted."
+msgstr ""
+"请为你修改的内容添加文档与测试。未注有文档或没有对应测试的特性会被拒绝。"
+
+#: ../../../CONTRIBUTING.rst:127 dc4db53c2ce34e5490a0c57ea800a4da
+msgid ""
+":pelican-doc:`Run all the tests ` **on all versions of Python"
+" supported by Pelican** to ensure nothing was accidentally broken."
+msgstr ""
+"**在Pelican支持的所有Python版本上** :pelican-doc:`执行所有测试 ` ,"
+"以确保没有意料之外的问题。"
+
+#: ../../../CONTRIBUTING.rst:130 3a88c2e8326a4acd896d0ac75d4c9ccb
+msgid ""
+"Check out our `Git Tips`_ page or `ask for help`_ if you need assistance "
+"or have any questions about these guidelines."
+msgstr ""
+"若需要帮助或对以上指南有任何疑惑,还可以查看我们的 `Git提示`_ 页面和 `请求帮助`_ 部分。"
+
+#: ../../contribute.rst:15 daead9e8fb804eb6acd152b85d837182
+msgid "Setting up the development environment"
+msgstr "配置开发环境"
+
+#: ../../contribute.rst:17 1ab6df98bcb141f49e278d153cc96e22
+msgid ""
+"While there are many ways to set up one's development environment, the "
+"following instructions will utilize Pip_ and PDM_. These tools facilitate"
+" managing virtual environments for separate Python projects that are "
+"isolated from one another, so you can use different packages (and package"
+" versions) for each."
+msgstr ""
+"在配置开发环境时往往有很多种方式,但下面的指南会使用 Pip_ 和 PDM_ 完成配置。这两个工具"
+"都可以用于管理虚拟环境,使得不同的Python项目相互隔离,这样就可以很方便的在不同的项目中"
+"使用不同的库(以及不同的库版本)。"
+
+#: ../../contribute.rst:22 6a9c8f6ddb1d495f8a9bd1b8a131cabd
+msgid "Please note that Python |min_python| is required for Pelican development."
+msgstr "请注意,要进行Pelican的开发,至少需要Python |min_python|"
+
+#: ../../contribute.rst:24 3d994e2a522141d7ada0a8fe13eb4c64
+msgid ""
+"*(Optional)* If you prefer to `install PDM "
+"`_ once for use with multiple"
+" projects, you can install it via::"
+msgstr ""
+"*(可选)* 若您想要 `安装PDM `_ ,"
+"可以使用下面这条命令:"
+
+#: ../../contribute.rst:29 dbaa532c292048cb87926dd8b6e3141a
+msgid ""
+"Point your web browser to the `Pelican repository`_ and tap the **Fork** "
+"button at top-right. Then clone the source for your fork and add the "
+"upstream project as a Git remote::"
+msgstr ""
+"在Web浏览器中进入 `Pelican的代码仓库`_ ,点击右上角的 **Fork** 按钮。然后克隆"
+"你自己的这份fork,最后添加项目的原仓库为远程仓库upstream:"
+
+#: ../../contribute.rst:38 adbe5d876f114645a3e1b489b2a34bd9
+msgid ""
+"While PDM can dynamically create and manage virtual environments, we're "
+"going to manually create and activate a virtual environment::"
+msgstr ""
+"通过下面的命令可以手动创建并激活一个虚拟环境:"
+
+#: ../../contribute.rst:45 ../../contribute.rst:181
+#: 6ede38ac05174bc19df4198e735342e0 f6d42cdd70384eaebbe115aefd0d01ec
+msgid "Install the needed dependencies and set up the project::"
+msgstr "安装必需的依赖并配置项目:"
+
+#: ../../contribute.rst:50 d863bf4dc76e4b18b933f2635a6a3af3
+msgid "Your local environment should now be ready to go!"
+msgstr "现在,你的本地开发环境就配置完成了!"
+
+#: ../../contribute.rst:57 dc19edf71c914f48a953b379efa076c0
+msgid "Development"
+msgstr "开发"
+
+#: ../../contribute.rst:59 6082eb5afbf14f86a031ed4f53d2943c
+msgid ""
+"Once Pelican has been set up for local development, create a topic branch"
+" for your bug fix or feature::"
+msgstr ""
+"在配置好Pelican的本地开发环境后,请先为你的bug修复或特性增加创建一个分支:"
+
+#: ../../contribute.rst:64 1cafbaea6ec04597b62e871c0f0793b2
+msgid ""
+"Now you can make changes to Pelican, its documentation, and/or other "
+"aspects of the project."
+msgstr ""
+"在切换到新建的分支后,就可以开始对Pelican的文档或其他内容做更改了。"
+
+#: ../../contribute.rst:68 e0f5da1e216f499d86427e21c23557d4
+msgid "Setting up ``git blame`` (optional)"
+msgstr "配置 ``git blame`` (可选)"
+
+#: ../../contribute.rst:70 2906e116c2dc4a2c8db78fa64820af56
+msgid ""
+"``git blame`` annotates lines in a file with information about the pull "
+"request that last modified it. Sweeping shallow changes (like formatting)"
+" can make that information less useful, so we keep a list of such changes"
+" to be ignored. Run the following command to set this up in your "
+"repository, adding ``--global`` if you want this setting to apply to all "
+"repositories::"
+msgstr ""
+"``git blame`` 会在文件中的行上标注有关最后一次修改该行的PR信息。对浅层变化(如格式化)"
+"进行批量更改可能会使这些信息变得不那么有用,因此我们维护一个包含此类更改的列表,"
+"以便忽略它们。运行以下命令在您的存储库中设置此配置,如果希望此设置适用于所有存储库,"
+"请添加 ``--global`` :"
+
+#: ../../contribute.rst:78 36f257406a294713835841cf549e0f67
+msgid ""
+"As noted in a `useful article`_ about ``git blame``, there are other "
+"related settings you may find to be beneficial::"
+msgstr ""
+"就像在 `这篇文章`_ 中提到的,还可以进行一些可能有用的额外设置:"
+
+#: ../../contribute.rst:89 37a3a813eeb84f408546bf6a83fdafd6
+msgid "Running the test suite"
+msgstr "运行测试套件"
+
+#: ../../contribute.rst:91 44276ab045104e5c9ab3d2425172d7ac
+msgid ""
+"Each time you make changes to Pelican, there are two things to do "
+"regarding tests: check that the existing tests pass, and add tests for "
+"any new features or bug fixes. The tests are located in "
+"``pelican/tests``, and you can run them via::"
+msgstr ""
+"每次对Pelican做出修改后,在测试方面需要做两个工作:检查是否能通过已有的测试、"
+"为新增特性或bug修复创建测试。请将自动化测试文件放在 ``pelican/tests`` 中,"
+"接着执行以下命令:"
+
+#: ../../contribute.rst:98 9557eb87ac4945ccbaf8775aa7768f6e
+msgid ""
+"(For more on Invoke, see ``invoke -l`` to list tasks, or "
+"https://pyinvoke.org for documentation.)"
+msgstr ""
+"(执行 ``invoke -l`` 会列出可以调用的测试任务,关于此的更多文档请参阅 "
+"https://pyinvoke.org )"
+
+#: ../../contribute.rst:101 d1cebbdf4fcf4be5b918613c5050d638
+msgid ""
+"In addition to running the test suite, it is important to also ensure "
+"that any lines you changed conform to code style guidelines. You can "
+"check that via::"
+msgstr ""
+"除了运行测试套件外,还要确保修改了的部分遵循代码风格指南。可以通过下面的命令"
+"检查代码风格:"
+
+#: ../../contribute.rst:106 7a0b9ebf408f472aa786f6c3ac639240
+msgid ""
+"If code style violations are found in lines you changed, correct those "
+"lines and re-run the above lint command until they have all been fixed. "
+"You do not need to address style violations, if any, for code lines you "
+"did not touch."
+msgstr ""
+"如果在修改过的代码中有地方违反了代码风格规范,请纠正并再次运行上述命令,直到全部纠正。"
+"但是若是发现违反代码风格的地方并不是你修改的,请忽略之,不要进行纠正。"
+
+#: ../../contribute.rst:110 74ec20f2daf74ad18cc083ad48b89dfe
+msgid ""
+"After making your changes and running the tests, you may see a test "
+"failure mentioning that \"some generated files differ from the expected "
+"functional tests output.\" If you have made changes that affect the HTML "
+"output generated by Pelican, and the changes to that output are expected "
+"and deemed correct given the nature of your changes, then you should "
+"update the output used by the functional tests. To do so, **make sure you"
+" have both** ``en_EN.utf8`` **and** ``fr_FR.utf8`` **locales installed**,"
+" and then run the following command::"
+msgstr ""
+"在修改完代码,运行测试的过程中,你可能会看到测试失败中有提到“some generated files "
+"differ from the expected functional tests output” 。这可能是由于你对代码的修改"
+"影响到了Pelican的HTML输出,若输出的结果确实是你想要的,请更新功能测试所用的输出用例。"
+"请确保你安装了 ``en_EN.utf8`` 和 ``fr_FR.utf8`` ,然后执行下述命令:"
+
+#: ../../contribute.rst:120 4299259dadd748238f9465eefb84727c
+msgid ""
+"You may also find that some tests are skipped because some dependency "
+"(e.g., Pandoc) is not installed. This does not automatically mean that "
+"these tests have passed; you should at least verify that any skipped "
+"tests are not affected by your changes."
+msgstr ""
+"你还可能会发现有一些测试由于缺少依赖(例如 Pandoc)而被跳过。这并不意味着通过"
+"了这些测试,请至少确保对代码的修改不会影响到这些被跳过的测试。"
+
+#: ../../contribute.rst:125 a8835ccddf624fc1994c618ded8cc5ba
+msgid ""
+"You should run the test suite under each of the supported versions of "
+"Python. This is best done by creating a separate Python environment for "
+"each version. Tox_ is a useful tool to automate running tests inside "
+"``virtualenv`` environments."
+msgstr ""
+"你应该在Pelican支持的所有Python版本下运行测试套件。一般会通过为每一个Python版本"
+"创建一个虚拟环境来实现这一点。Tox_ 是一个用于在 ``virtualenv`` 环境中自动运行"
+"测试的工具。"
+
+#: ../../contribute.rst:133 b8b8c16b0d0743b98de5d759f79d07ba
+msgid "Running a code coverage report"
+msgstr "运行代码测试覆盖报告"
+
+#: ../../contribute.rst:135 674a92a42d924931801c9f9c02463cd5
+msgid ""
+"Code is more likely to stay robust if it is tested. Coverage_ is a "
+"library that measures how much of the code is tested. To run it::"
+msgstr ""
+"经过测试的代码往往具有更好的健壮性。 Coverage_ 是一个用于衡量代码测试覆盖率的库"
+"执行下面的命令以调取之:"
+
+#: ../../contribute.rst:140 ecb5e7f9e83c4243ba04b58764e573b6
+msgid ""
+"This will show overall coverage, coverage per file, and even line-by-line"
+" coverage. There is also an HTML report available::"
+msgstr ""
+"该命令会展示总体覆盖率以及在每个文件上的覆盖率,甚至还会展示每一行的覆盖情况。"
+"同样也会有一份HTML格式的报告供您查看:"
+
+#: ../../contribute.rst:148 bad31d4cb0b644ac8ecb7885b22072a7
+msgid "Building the docs"
+msgstr "构建文档"
+
+#: ../../contribute.rst:150 47e1f1caa594462d9b3b4403645abf3b
+msgid ""
+"If you make changes to the documentation, you should build and inspect "
+"your changes before committing them::"
+msgstr ""
+"若你对文档进行过修改,请在commit前完成构建和检查:"
+
+#: ../../contribute.rst:155 a4961ae22c2c4de9bbc8bb98d3a3ec81
+msgid ""
+"Open http://localhost:8000 in your browser to review the documentation. "
+"While the above task is running, any changes you make and save to the "
+"documentation should automatically appear in the browser, as it live-"
+"reloads when it detects changes to the documentation source files."
+msgstr ""
+"执行上述命令后,请在Web浏览器中打开 http://localhost:8000 来查看文档。"
+"在上述命令执行时,对文档做的任何修改应该会自动反映在浏览器中。"
+
+#: ../../contribute.rst:161 7740ec477ad747ebaa2dde2b2aef45d5
+msgid "Plugin development"
+msgstr "插件开发"
+
+#: ../../contribute.rst:163 9505da5fcac24d718f59c797061d2b0f
+msgid ""
+"To create a *new* Pelican plugin, please refer to the `plugin template`_ "
+"repository for detailed instructions."
+msgstr ""
+"要创建一个 *新的* Pelican插件,请参阅 `插件模板`_ 仓库以获得更为详细的指导。"
+
+#: ../../contribute.rst:166 5fdae4611a6949b9a4c3bc82c52d3bc6
+msgid ""
+"If you want to contribute to an *existing* Pelican plugin, follow the "
+"steps above to set up Pelican for local development, and then create a "
+"directory to store cloned plugin repositories::"
+msgstr ""
+"若你想在 *已有* Pelican插件中做贡献,请先按前文所述步骤配置Pelican的本地开发环境,"
+"然后创建一个文件夹来存放克隆下来的插件仓库:"
+
+#: ../../contribute.rst:172 0f50b12aaf3b4049999130a92fa6b670
+msgid ""
+"Assuming you wanted to contribute to the Simple Footnotes plugin, you "
+"would first browse to the `Simple Footnotes`_ repository on GitHub and "
+"tap the **Fork** button at top-right. Then clone the source for your fork"
+" and add the upstream project as a Git remote::"
+msgstr ""
+"假设想要为Simple Footnotes插件做贡献,你应该先查看并fork `Simple Footnotes`_ "
+"的Github仓库,然后克隆你自己fork的那一份,再添加原仓库作为Git远程仓库upstream:"
+
+#: ../../contribute.rst:185 2efe992372f149c3b63ca22016f8501b
+msgid "Create a topic branch for your plugin bug fix or feature::"
+msgstr "同样地,为你想要进行的bug修复或特性添加创建一个分支:"
+
+#: ../../contribute.rst:189 40f3c07d12cc4630bc75355c3449196d
+msgid ""
+"After writing new tests for your plugin changes, run the plugin test "
+"suite and check for code style compliance via::"
+msgstr ""
+"完成修改并添加测试后,运行测试套件,并检查代码风格:"
+
+#: ../../contribute.rst:195 ba97ce962daa437cbcf2d09897394aed
+msgid ""
+"If style violations are found, many of them can be addressed "
+"automatically via::"
+msgstr ""
+"若存在不合规范风格的代码,大多数情况下可以通过下述命令自动纠正:"
+
+#: ../../contribute.rst:199 a0ee1e11aaea4f5c8ba4c4704678bbaf
+msgid ""
+"If style violations are found even after running the above auto-"
+"formatters, you will need to make additional manual changes until "
+"``invoke lint`` no longer reports any code style violations."
+msgstr ""
+"如果在自动格式化后仍存在代码风格上的问题,请手动修正这些问题,直到执行 "
+"``invoke lint`` 时不再报告问题。"
+
+#: ../../contribute.rst:207 e9d1e344bb0d4b2fb9d08c2d71d9a342
+msgid "Submitting your changes"
+msgstr "提交更改"
+
+#: ../../contribute.rst:209 716c9f94166d42299d9ee58eed4f9b53
+msgid ""
+"Assuming linting validation and tests pass, add a ``RELEASE.md`` file in "
+"the root of the project that contains the release type (major, minor, "
+"patch) and a summary of the changes that will be used as the release "
+"changelog entry. For example::"
+msgstr ""
+"通过了风格检查和所有测试后,请在项目的根目录下添加一个 ``RELEASE.md`` 文件,"
+"其中应包含发布的类型(major、minor、patch)以及代码变更的摘要,这份摘要会被用作"
+"更新日志的条目。下面是一个例子:"
+
+#: ../../contribute.rst:218 656309283e5642b99981c84da9b04c86
+msgid "Commit your changes and push your topic branch::"
+msgstr "commit你的更改,并push对应分支:"
+
+#: ../../contribute.rst:224 16617b687db94783b5488884e4c9be1b
+msgid ""
+"Finally, browse to your repository fork on GitHub and submit a pull "
+"request."
+msgstr ""
+"最后,前往Github,从你fork的仓库向原仓库提出PR。"
+
+#: ../../contribute.rst:228 629ae326bd4e4718a8865d3925c02c3e
+msgid "Logging tips"
+msgstr "日志技巧"
+
+#: ../../contribute.rst:230 486bb6ae6c484431923a96b7a7aff0c5
+msgid "Try to use logging with appropriate levels."
+msgstr "请仔细斟酌合适的日志等级。"
+
+#: ../../contribute.rst:232 fbe2aed8f0f5412081461fce5d36e51e
+msgid "For logging messages that are not repeated, use the usual Python way::"
+msgstr "对于不重复的日志消息,使用一般的方式即可:"
+
+#: ../../contribute.rst:241 bab220240a0744f5b1170783098b5eac
+#, python-format
+msgid ""
+"Do not format log messages yourself. Use ``%s`` formatting in messages "
+"and pass arguments to logger. This is important, because the Pelican "
+"logger will preprocess some arguments, such as exceptions."
+msgstr ""
+"请不要自己格式化日志消息,而是使用在日志消息中使用 ``%s`` 并向logger传入参数。请务必"
+"遵循这一规则,因为Pelican的logger会自动预处理一些特殊的参数,例如exception。"
+
+#: ../../contribute.rst:246 a760419565b8440ebc8b4dc8898520db
+msgid "Limiting extraneous log messages"
+msgstr "限制低关联日志消息"
+
+#: ../../contribute.rst:248 dcf900d9f7d0424fabff4a9c5a7e5dc8
+msgid ""
+"If the log message can occur several times, you may want to limit the log"
+" to prevent flooding. In order to do that, use the ``extra`` keyword "
+"argument for the logging message in the following format::"
+msgstr ""
+"如果同一日志消息会重复多次,你会希望限制这些多余的内容。使用 ``extra`` "
+"命名参数来实现这一点:"
+
+#: ../../contribute.rst:255 1ca7d769fc9348f8a5f9eef7b614522b
+msgid ""
+"Optionally, you can also set ``'limit_args'`` as a tuple of arguments in "
+"``extra`` dict if your generic message needs formatting."
+msgstr ""
+"可选的,如果通用日志消息需要格式化,可以添加 ``'limit_args'`` 参数并将其对应值"
+"设为一个元组。"
+
+#: ../../contribute.rst:258 85328a267c464f9aaacb1b0ef289d624
+msgid ""
+"Limit is set to ``5``, i.e, first four logs with the same ``'limit_msg'``"
+" are outputted normally but the fifth one will be logged using "
+"``'limit_msg'`` (and ``'limit_args'`` if present). After the fifth, "
+"corresponding log messages will be ignored."
+msgstr ""
+"限制数默认设为了 ``5`` ,即前四个有相同 ``'limit_msg'`` 参数的日志消息会正常输出,"
+"但第五条这样的日志消息会呈现为 ``'limit_msg'`` 参数值本身( ``'limit_args'`` 同理)。"
+"第六条及之后的日志消息会被直接忽略。"
+
+#: ../../contribute.rst:263 7a51dbb9559d4a579654b2ab0938d09b
+msgid ""
+"For example, if you want to log missing resources, use the following "
+"code::"
+msgstr ""
+"例如,如果你想要用日志记录资源缺失的信息,可以使用下面的代码:"
+
+#: ../../contribute.rst:271 8db05f7332f3475b940fb79d24e74ce7
+msgid "The log messages will be displayed as follows::"
+msgstr "最终的日志消息看起来会像这样:"
+
+#: ../../contribute.rst:281 93d618c58e6e4688bebb999ddf591eaa
+msgid "Outputting traceback in the logs"
+msgstr "在日志中输出traceback信息"
+
+#: ../../contribute.rst:283 3d56bb4bc804499a8d3c8f14dc614916
+msgid ""
+"If you're logging inside an ``except`` block, you may want to provide the"
+" traceback information as well. You can do that by setting ``exc_info`` "
+"keyword argument to ``True`` during logging. However, doing so by default"
+" can be undesired because tracebacks are long and can be confusing to "
+"regular users. Try to limit them to ``--debug`` mode like the following::"
+msgstr ""
+"当在 ``except`` 块中进行日志记录时,你可能会希望同时输出traceback信息。可以"
+"简单地将 ``exc_info`` 参数设为 ``True`` 来实现这一功能。但是通过此方法输出的"
+"traceback信息会非常长,不便于理解。可以像下述代码一样将这些信息限制在 "
+"``--debug`` 模式中:"
+
+#~ msgid "latest Pelican release (or an up-to-date Git clone of Pelican master)"
+#~ msgstr ""
+
+#~ msgid ""
+#~ "`Create a new branch`_ specific to "
+#~ "your change (as opposed to making "
+#~ "your commits in the master branch)."
+#~ msgstr ""
diff --git a/docs/locale/zh_CN/LC_MESSAGES/faq.po b/docs/locale/zh_CN/LC_MESSAGES/faq.po
new file mode 100644
index 00000000..81712a82
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/faq.po
@@ -0,0 +1,457 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-07-31 22:54+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../faq.rst:2 87acb7c16d974b4eb060949b8ce40914
+msgid "Frequently Asked Questions (FAQ)"
+msgstr "常见问题解答"
+
+#: ../../faq.rst:4 76aee892f7f14d0590db2d76c7cc0123
+msgid "Here are some frequently asked questions about Pelican."
+msgstr "以下是一些Pelican的常见问题解答。"
+
+#: ../../faq.rst:7 c98549fdd5814984bfa3a6eaf4631d37
+msgid "What's the best way to communicate a problem, question, or suggestion?"
+msgstr "交流问题、疑问或提建议的最佳方式是什么?"
+
+#: ../../faq.rst:9 dbecb306adeb482ba3b9bd68483bc372
+msgid "Please read our :doc:`feedback guidelines `."
+msgstr "请参阅文档 :doc:`项目贡献与意见反馈 ` 。"
+
+#: ../../faq.rst:12 8fe91d51140946f1b2cb131d786c1814
+msgid "How can I help?"
+msgstr "我可以帮上什么忙?"
+
+#: ../../faq.rst:14 d8477da414c446b3936e73931eb4f63a
+msgid ""
+"There are several ways to help out. First, you can communicate any "
+"Pelican suggestions or problems you might have via `Pelican Discussions "
+"`_. Please first check"
+" the existing list of discussions and issues (both open and closed) in "
+"order to avoid submitting topics that have already been covered before."
+msgstr ""
+"有好多种方法可以提供帮助。首先,可以在 `Pelican讨论板块 "
+"`_ "
+"中提出任何关于Pelican的建议或是问题。在提问或建议之前,请先查看已关闭或开放的issues中是否已有相关内容,以避免内容上的重复。"
+
+#: ../../faq.rst:20 95a29a97e08a452f89aa4eaad191b698
+msgid ""
+"If you want to contribute, please fork `the Git repository "
+"`_, create a new feature branch, "
+"make your changes, and issue a pull request. Someone will review your "
+"changes as soon as possible. Please refer to the :doc:`How to Contribute "
+"` section for more details."
+msgstr ""
+"如果你想要对项目进行贡献,请fork `Git仓库 `_ "
+",创建一个新的功能分支,并在其中进行修改,在修改完成后提出一个PR。项目组会尽快审核你的PR。关于此的更多内容,请参见 "
+":doc:`项目贡献与意见反馈 ` 一节。"
+
+#: ../../faq.rst:26 bf7a6828eec74dc588c18e185bdd7090
+msgid ""
+"You can also contribute by creating themes and improving the "
+"documentation."
+msgstr "你可以发起的贡献当然也包括创建主题和改进文档。"
+
+#: ../../faq.rst:29 2ce846241ce744fd81981a376d3f5fe2
+msgid "Is the Pelican settings file mandatory?"
+msgstr "Pelican配置文件是必要的吗?"
+
+#: ../../faq.rst:31 527720062339422095e2c95755af5584
+msgid ""
+"Configuration files are optional and are just an easy way to configure "
+"Pelican. For basic operations, it's possible to specify options while "
+"invoking Pelican via the command line. See ``pelican --help`` for more "
+"information."
+msgstr ""
+"配置文件是可选的,其本质是使您可以更方便地配置Pelican。对于一些基本的配置操作,完全可以在命令行中指定,调用 ``pelican "
+"--help`` 可以查看pelican命令的更多信息。"
+
+#: ../../faq.rst:36 d0ca19a2e40c4ecaa9ecba6cc677f142
+msgid "Changes to the settings file take no effect"
+msgstr "修改后的配置文件没有生效"
+
+#: ../../faq.rst:38 5b741cbb28854893818826c593f8e323
+msgid ""
+"When experimenting with different settings (especially the metadata ones)"
+" caching may interfere and the changes may not be visible. In such cases,"
+" ensure that caching is disabled via ``LOAD_CONTENT_CACHE = False`` or "
+"use the ``--ignore-cache`` command-line switch."
+msgstr ""
+"在尝试不同的配置时(尤其是尝试不同元数据时),缓存很可能会产生干扰,使得修改不可见。此时,确保配置了 ``LOAD_CONTENT_CACHE ="
+" False`` 或在命令行中加上 ``--ignore-cache`` 以禁用缓存。"
+
+#: ../../faq.rst:44 439f2221927b42f7a4c219ab1a76f849
+msgid "I'm creating my own theme. How do I use Pygments for syntax highlighting?"
+msgstr "在自己创建主题时,如何使用Pygments来调整语法高亮?"
+
+#: ../../faq.rst:46 3475c1550e584c84a118ac061461f9f6
+msgid ""
+"Pygments adds some classes to the generated content. These classes are "
+"used by themes to style code syntax highlighting via CSS. Specifically, "
+"you can customize the appearance of your syntax highlighting via the "
+"``.highlight pre`` class in your theme's CSS file. To see how various "
+"styles can be used to render Django code, for example, use the style "
+"selector drop-down at top-right on the `Pygments project demo site "
+"`_."
+msgstr ""
+"Pygments会为生成的内容添加一些CSS类。这些类会为主题所用,主题会通过CSS来为代码添加语法高亮。具体来说,你可以通过主题CSS文件中的 "
+"``.highlight pre`` 类来自定义语法高亮的外观。在 `Pygments 项目的demo网站 "
+"`_ 上可以预览能够渲染的代码类型。"
+
+#: ../../faq.rst:53 ecffb1f9501f46c88f799b79fc0ba343
+msgid ""
+"You can use the following example commands to generate a starting CSS "
+"file from a Pygments built-in style (in this case, \"monokai\") and then "
+"copy the generated CSS file to your new theme::"
+msgstr "你可以使用下面的命令来让Pygments使用内置风格(此处为“monokai”)生成一个初始CSS文件,然后将此文件拷贝到新主题中:"
+
+#: ../../faq.rst:60 8fc71763c5c243339c9e737cc55b99da
+msgid "Don't forget to import your ``pygment.css`` file from your main CSS file."
+msgstr "不要忘了在你的CSS主文件中引入 ``pygment.css`` 文件。"
+
+#: ../../faq.rst:63 ad118f1f46db423fab19f570cd789798
+msgid "How do I create my own theme?"
+msgstr "如何创建我自己的主题?"
+
+#: ../../faq.rst:65 1674585960e742cbade644b63d3bb32a
+msgid "Please refer to :ref:`theming-pelican`."
+msgstr "请参阅 :ref:`theming-pelican` 。"
+
+#: ../../faq.rst:68 b06c6a8df1634d20b988515af6536e2c
+msgid "I want to use Markdown, but I got an error."
+msgstr "我想要使用Markdown,但是出错了。"
+
+#: ../../faq.rst:70 c0a89314dbdf4368b2e32d781c0ae95b
+msgid ""
+"If you try to generate Markdown content without first installing the "
+"Markdown library, you may see a message that says ``No valid files found "
+"in content``. Markdown is not a hard dependency for Pelican, so if you "
+"have content in Markdown format, you will need to explicitly install the "
+"Markdown library. You can do so by typing the following command, "
+"prepending ``sudo`` if permissions require it::"
+msgstr ""
+"如果没有事先安装Markdown库,在生成Markdown内容时会看到一条提示 ``No valid files found in "
+"content`` "
+"。虽然Markdown并不是必需依赖,但如果你写的内容中含有Markdown格式,就需要安装Markdown库了。输入下面的命令以安装Markdown库,如果需要权限,请在前面添加"
+" ``sudo`` :"
+
+#: ../../faq.rst:80 a4c93b71eb914652b3f05357067f87b3
+msgid "Can I use arbitrary metadata in my templates?"
+msgstr "在模板中可以使用任意元数据吗?"
+
+#: ../../faq.rst:82 6ac1579e5d8842f5bf97b87745848c6a
+msgid ""
+"Yes. For example, to include a modified date in a Markdown post, one "
+"could include the following at the top of the article::"
+msgstr "当然可以。例如,可以在Markdown帖子中包含一个“修改日期”,加在文章开头即可:"
+
+#: ../../faq.rst:87 d1ad8fa8e07c4500ab754962064749a8
+msgid ""
+"For reStructuredText, this metadata should of course be prefixed with a "
+"colon::"
+msgstr "对于reStructuredText,此元数据也应当以冒号为前缀:"
+
+#: ../../faq.rst:91 e3c9814b5b3849a7957f964565038e45
+msgid ""
+"This metadata can then be accessed in templates such as ``article.html`` "
+"via::"
+msgstr "此元数据可以在模板中获取到,例如在 ``article.html`` 中,可以像这样获取:"
+
+#: ../../faq.rst:97 11d953b5718c4baeb7f7fbbb9538c763
+msgid ""
+"If you want to include metadata in templates outside the article context "
+"(e.g., ``base.html``), the ``if`` statement should instead be::"
+msgstr "如果您想在其他模板(例如 ``base.html`` )中获取此元数据,则 ``if`` 语句应改为:"
+
+#: ../../faq.rst:103 99ca0aeea6d14c159cf1f1b8d9cf016d
+msgid ""
+"How do I make my output folder structure identical to my content "
+"hierarchy?"
+msgstr "如何使得输出目录的结构和content目录的结构保持一致?"
+
+#: ../../faq.rst:105 e97223e6c7c94c08a1d42f783fd67f7e
+msgid "Try these settings::"
+msgstr "可以尝试如下配置:"
+
+#: ../../faq.rst:112 d35f11a227ba421596458ea8f26ecde0
+msgid "How do I assign custom templates on a per-page basis?"
+msgstr "如何为某个页面指定某个模板?"
+
+#: ../../faq.rst:114 287bac0946dc47feab068bdb76d0bc2e
+msgid ""
+"It's as simple as adding an extra line of metadata to any page or article"
+" that you want to have its own template. For example, this is how it "
+"would be handled for content in reST format::"
+msgstr "这非常简单,在任何页面或者文章中,都可以通过多添加一行元数据来指定特定模板。例如,在reST中,使用:"
+
+#: ../../faq.rst:120 b845784299bf47629e616505000724c1
+msgid "For content in Markdown format::"
+msgstr "对于Markdown,则使用:"
+
+#: ../../faq.rst:124 fa734dbb540e4cda8a5be5fb1b2da124
+msgid ""
+"Then just make sure your theme contains the relevant template file (e.g. "
+"``template_name.html``)."
+msgstr "确保对应的模板文件在主题中存在即可(例如 ``template_name.html`` )。"
+
+#: ../../faq.rst:128 bdee9be4397f4839855295ee1a0fdd12
+msgid "How can I override the generated URL of a specific page or article?"
+msgstr "如何重写某一个页面或文章生成的URL?"
+
+#: ../../faq.rst:130 ed91b5bdcbe24473a6fed738784311b8
+msgid ""
+"Include ``url`` and ``save_as`` metadata in any pages or articles that "
+"you want to override the generated URL. Here is an example page in reST "
+"format::"
+msgstr "在任意页面或文章中都可以添加 ``url`` 和 ``save_as`` 元数据,这样就可以重写URL了。下面以reST格式为例:"
+
+#: ../../faq.rst:139 5aa733d8d3bd4d86920e7e142715b1f4
+msgid ""
+"With this metadata, the page will be written to "
+"``override/url/index.html`` and Pelican will use the URL "
+"``override/url/`` to link to this page."
+msgstr ""
+"有了这样的元数据,此页面会保存为 ``override/url/index.html`` ,Pelican会将 ``override/url/``"
+" 作为链接到此页面的URL。"
+
+#: ../../faq.rst:143 04d9890aa34d4c1e86bc7a49cd64938a
+msgid "How can I use a static page as my home page?"
+msgstr "如何使用一个静态页面作为主页?"
+
+#: ../../faq.rst:145 d3e8a4e2d453446f9037fa46e6775080
+msgid ""
+"The override feature mentioned above can be used to specify a static page"
+" as your home page. The following Markdown example could be stored in "
+"``content/pages/home.md``::"
+msgstr "上一个问题中提到的特性可以用于实现此需求。下面例子中的Markdown文件保存为 ``content/pages/home.md`` :"
+
+#: ../../faq.rst:155 739da75e7ce946af99c9f577e8a284ff
+msgid ""
+"If the original blog index is still wanted, it can then be saved in a "
+"different location by setting ``INDEX_SAVE_AS = 'blog_index.html'`` for "
+"the ``'index'`` direct template."
+msgstr ""
+"如果仍需要原来的博客主页(即 ``'index'`` 直接模板),可以通过设置 ``INDEX_SAVE_AS = "
+"'blog_index.html'`` 将其存储在其他位置。"
+
+#: ../../faq.rst:160 5224f09821d24e4a8db6870da1266a20
+msgid "What if I want to disable feed generation?"
+msgstr "可以禁用订阅源生成吗?"
+
+#: ../../faq.rst:162 8f014ffab3c44b0ebf2b0d9872bfbfa7
+msgid ""
+"To disable feed generation, all feed settings should be set to ``None``. "
+"All but three feed settings already default to ``None``, so if you want "
+"to disable all feed generation, you only need to specify the following "
+"settings::"
+msgstr ""
+"要禁用订阅源,所有订阅源相关的配置都应被设为 ``None`` 。其中有三项设置默认为 ``None`` "
+",因此如果要彻底不生成订阅源,你只需要指定下面这些设置:"
+
+#: ../../faq.rst:172 9ab29ccca83c4ecfabcb3ad4dd17c751
+msgid ""
+"The word ``None`` should not be surrounded by quotes. Please note that "
+"``None`` and ``''`` are not the same thing."
+msgstr "``None`` 两侧不需要加引号。请注意 ``None`` 和 ``''`` 不是同一个东西。"
+
+#: ../../faq.rst:176 fd8cbe4962d145ccadfd480419dbea9e
+msgid ""
+"I'm getting a warning about feeds generated without SITEURL being set "
+"properly"
+msgstr "Pelican警告说由于SITEURL设置不正确,无法正常生成订阅源"
+
+#: ../../faq.rst:178 e3135e5903ec422f8d7895866ca6f365
+msgid ""
+"`RSS and Atom feeds require all URL links to be absolute "
+"`_. In order to "
+"properly generate links in Pelican you will need to set ``SITEURL`` to "
+"the full path of your site."
+msgstr ""
+"`RSS和Atom订阅源要求所有URL都要链接到绝对地址 "
+"`_ "
+"。为了使得Pelican能正确生成链接,你需要将站点的 ``SITEURL`` 设置为完整路径。"
+
+#: ../../faq.rst:183 4f2cd929dda7464cbd577d1249969920
+msgid ""
+"Feeds are still generated when this warning is displayed, but links "
+"within may be malformed and thus the feed may not validate."
+msgstr "虽然Pelican提出了警告,但是仍会生成订阅源,但其中的链接可能是无效的,这会导致订阅源不可用。"
+
+#: ../../faq.rst:187 a9f3465fda8c4a0d9395b2d6d9d5478f
+msgid "Can I force Atom feeds to show only summaries instead of article content?"
+msgstr "可以让Atom订阅源只显示摘要,不显示文章内容吗?"
+
+#: ../../faq.rst:189 baf140533501453aa8caeddfc276d8fb
+msgid ""
+"Instead of having to open a separate browser window to read articles, the"
+" overwhelming majority of folks who use feed readers prefer to read "
+"content within the feed reader itself. Mainly for that reason, Pelican "
+"does not support restricting Atom feeds to only contain summaries. Unlike"
+" Atom feeds, the RSS feed specification does not include a separate "
+"``content`` field, so by default Pelican publishes RSS feeds that only "
+"contain summaries (but can optionally be set to instead publish full "
+"content RSS feeds). So the default feed generation behavior provides "
+"users with a choice: subscribe to Atom feeds for full content or to RSS "
+"feeds for just the summaries."
+msgstr ""
+"绝大多数使用订阅源阅读器的人都更喜欢直接在阅读器中阅读文章内容,而不是另外再打开窗口来阅读。因此,Pelican不支持使Atom只包含摘要。但是由于RSS不包含单独的"
+" ``content`` "
+"字段,因此Pelican在发布RSS时默认只包含摘要(当然也可以设置为包含文章内容)。Pelican在订阅源生成上的如此行为就可以让用户自行选择订阅类型:包含了完整内容的Atom或是只包含摘要的RSS。"
+
+#: ../../faq.rst:200 850ac093f2764547a7df74d5d055cbd4
+msgid "Is Pelican only suitable for blogs?"
+msgstr "Pelican只适合用于博客吗?"
+
+#: ../../faq.rst:202 1fb5d92096b242d09da5e0e490b34685
+msgid ""
+"No. Pelican can be easily configured to create and maintain any type of "
+"static site. This may require a little customization of your theme and "
+"Pelican configuration. For example, if you are building a launch site for"
+" your product and do not need tags on your site, you could remove the "
+"relevant HTML code from your theme. You can also disable generation of "
+"tag-related pages via::"
+msgstr "不是的。Pelican可以方便地用于创建维护任何静态站点,为此你需要对主题和配置做一些定制。例如,如果要为你的产品构建一个宣传网站,即不需要使用标签特性,从主题中移除与标签相关的HTML代码即可。另外,还可以通过下面的设置来禁用标签相关页面的生成:"
+
+#: ../../faq.rst:212 5452959b3b694cbc89bb8e91bfbef840
+msgid ""
+"Why does Pelican always write all HTML files even with content caching "
+"enabled?"
+msgstr "启用内容缓存后,为什么Pelican仍会每次都写入所有HTML文件?"
+
+#: ../../faq.rst:214 b27b4b7256f749f1bc5970b95fa742ab
+msgid ""
+"In order to reliably determine whether the HTML output is different "
+"before writing it, a large part of the generation environment including "
+"the template contexts, imported plugins, etc. would have to be saved and "
+"compared, at least in the form of a hash (which would require special "
+"handling of unhashable types), because of all the possible combinations "
+"of plugins, pagination, etc. which may change in many different ways. "
+"This would require a lot more processing time and memory and storage "
+"space. Simply writing the files each time is a lot faster and a lot more "
+"reliable."
+msgstr "为了确定HTML输出确实和之前的不同,模板上下文、插件等很多生成环境都需要保存并比较某种哈希值(对于不可哈希的内容类型还需要进行一些额外处理)。另外,由于插件、分页等内容的存在,输出的HTML很可能会与之前不同。因此,考虑到处理时间和存储空间,每次都重新写入全部HTML会更快更可靠。"
+
+#: ../../faq.rst:223 dcb5b1cf0e1b413bb7c04f6deb4ad5d7
+msgid ""
+"However, this means that the modification time of the files changes every"
+" time, so a ``rsync`` based upload will transfer them even if their "
+"content hasn't changed. A simple solution is to make ``rsync`` use the "
+"``--checksum`` option, which will make it compare the file checksums in a"
+" much faster way than Pelican would."
+msgstr ""
+"然而,这样的机制会使得在每次生成站点后,文件的修改时间都会变化,因此基于 ``rsync`` "
+"上传时会把没有变化的内容也进行上传。一个简便的解决方法就是给 ``rsync`` 加上 ``--checksum`` "
+"选项,这会比Pelican在生成时进行校验更快。"
+
+#: ../../faq.rst:230 628a1180f3fd4c0b8301b33e0728d2c2
+msgid "How to process only a subset of all articles?"
+msgstr "如何只处理一部分文章?"
+
+#: ../../faq.rst:232 c2bfe768775342bb8386255ea1bbbe4e
+msgid ""
+"It is often useful to process only e.g. 10 articles for debugging "
+"purposes. This can be achieved by explicitly specifying only the "
+"filenames of those articles in ``ARTICLE_PATHS``. A list of such "
+"filenames could be found using a command similar to ``cd content; find "
+"-name '*.md' | head -n 10``."
+msgstr ""
+"简便起见,在调试时可能只需要处理几篇文章。可以直接在配置项 ``ARTICLE_PATHS`` 中添加需要处理文章的文件名。可以通过像 ``cd "
+"content; find -name '*.md' | head -n 10`` 这样的命令获取文章文件名的列表。"
+
+#: ../../faq.rst:238 72d30cb7a6e348c483cba0c6b6de8d3a
+msgid "My tag cloud is missing/broken since I upgraded Pelican"
+msgstr "在升级Pelican后,标签云消失或不可用了"
+
+#: ../../faq.rst:240 7d07dcddab5d42d1aab6a8dbd27ce36c
+msgid ""
+"In an ongoing effort to streamline Pelican, tag cloud generation has been"
+" moved out of Pelican core and into a separate `plugin "
+"`_. See the :ref:`plugins` "
+"documentation for further information about the Pelican plugin system."
+msgstr ""
+"我们一直致力于精简Pelican,标签云生成的功能已经从Pelican核心中移除,转而放到了一个单独的 `tag-cloud插件 "
+"`_ 中。查看 :ref:`plugins` "
+"文档获取更多关于Pelican插件系统的信息。"
+
+#: ../../faq.rst:246 51c727bc21f946b8915f958312369e0f
+msgid "Since I upgraded Pelican my pages are no longer rendered"
+msgstr "升级Pelican后,一些页面没有被渲染"
+
+#: ../../faq.rst:248 4a0d962bc2d844cbab3d0b3e7f6f7bba
+msgid ""
+"Pages were available to themes as lowercase ``pages`` and uppercase "
+"``PAGES``. To bring this inline with the :ref:`templates-variables` "
+"section, ``PAGES`` has been removed. This is quickly resolved by updating"
+" your theme to iterate over ``pages`` instead of ``PAGES``. Just "
+"replace::"
+msgstr ""
+"在以前的版本中,主题通过小写的 ``pages`` 和大写的 ``PAGES`` 都能获取到页面。为了使之与 :ref:`templates-"
+"variables` 一节中的内容保持一致,大写的 ``PAGES`` 被删除了。只要将主题中的 ``PAGES`` 替换为 ``pages`` "
+",问题即可解决。例如将原先的:"
+
+#: ../../faq.rst:255 6167ad6b52db43d384247747db1884ca
+msgid "with something like::"
+msgstr "替换为:"
+
+#: ../../faq.rst:260 a7a04eb9e8e549fa8a2a72db3f35b532
+msgid "How can I stop Pelican from trying to parse my static files as content?"
+msgstr "如何避免让Pelican将我的静态文件解析为内容文件?(译者注:例如要将一个HTML文件作为静态文件)?"
+
+#: ../../faq.rst:262 6baaf265738d4acaa26f7829c64a0ac5
+msgid ""
+"Pelican's article and page generators run before it's static generator. "
+"That means if you use a setup similar to the default configuration, where"
+" a static source directory is defined inside a ``*_PATHS`` setting, all "
+"files that have a valid content file ending (``.html``, ``.rst``, "
+"``.md``, ...) will be treated as articles or pages before they get "
+"treated as static files."
+msgstr ""
+"Pelican的文章与页面生成器会先于静态文件生成器运行。这意味着若使用默认配置,即静态资源文件夹定义在某个 ``*_PATHS`` "
+"配置项中,所有以有效内容文件后缀结尾的文件( ``.html`` 、 ``.rst`` 、 ``.md`` "
+"等)都会被视为文章或者页面,而不是静态文件。"
+
+#: ../../faq.rst:268 e4591dd94ddd4199900b9a451d12929e
+msgid ""
+"To circumvent this issue either use the appropriate ``*_EXCLUDES`` "
+"setting or disable the offending reader via ``READERS`` if you don't need"
+" it."
+msgstr ""
+"为了避免这个问题,使用合适的 ``*_EXCLUDES`` 配置,在必要时还可以通过 ``READERS`` "
+"配置项来直接禁用产生问题的reader。"
+
+#: ../../faq.rst:272 ca927fe2be10411ab365bcc3e4fa4dbd
+msgid "Why is [arbitrary Markdown syntax] not supported?"
+msgstr "为什么不是所有的Markdown语法都支持?"
+
+#: ../../faq.rst:274 5c9cc929a6bf4f1db9d4eed5f37fc0af
+msgid ""
+"Pelican does not directly handle Markdown processing and instead "
+"delegates that task to the Python-Markdown_ project, the core of which "
+"purposefully follows the original Markdown syntax rules and not the "
+"myriad Markdown \"flavors\" that have subsequently propagated. That said,"
+" Python-Markdown_ is quite modular, and the syntax you are looking for "
+"may be provided by one of the many available `Markdown Extensions`_. "
+"Alternatively, some folks have created Pelican plugins that support "
+"Markdown variants, so that may be your best choice if there is a "
+"particular variant you want to use when writing your content."
+msgstr ""
+"Pelican并不直接对Markdown进行处理,而是将此任务交给 Python-Markdown_ "
+"项目,此项目的核心有意只遵循原始的Markdown语法规则,而不服从之后传播开的大量Markdown风格。另外, Python-Markdown_"
+" 是相当模块化的,你想要使用的语法可能已经有现成的 `Markdown扩展`_ "
+"进行了实现。或者,也有人创建了支持Markdown变体的Pelican插件,如果你想要用某种Markdown变体,可以在这些地方寻找支持。"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/importer.po b/docs/locale/zh_CN/LC_MESSAGES/importer.po
new file mode 100644
index 00000000..9e015c1a
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/importer.po
@@ -0,0 +1,321 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../importer.rst:4 2e58a5582f664ba0af49aac4480bc799
+msgid "Importing an existing site"
+msgstr "导入已有站点"
+
+#: ../../importer.rst:7 5182de0b717543c7a4813491755b720a
+msgid "Description"
+msgstr "简介"
+
+#: ../../importer.rst:9 29a8bae0ba78486894ed4c286cd2f3b4
+msgid ""
+"``pelican-import`` is a command-line tool for converting articles from "
+"other software to reStructuredText or Markdown. The supported import "
+"formats are:"
+msgstr ""
+"命令行工具 ``pelican-import`` 用于将其他软件生成的文章转换成reStructuredText"
+"或Markdown格式。支持导入下面这些格式:"
+
+#: ../../importer.rst:12 c670f6055ad24d818132d74951c9928c
+msgid "Blogger XML export"
+msgstr "Blogger XML export"
+
+#: ../../importer.rst:13 d31ddaa8c7d54a268b379f706164de39
+msgid "Dotclear export"
+msgstr "Dotclear export"
+
+#: ../../importer.rst:14 5102eb70c58240b2ad4d508a196b176e
+msgid "Medium export"
+msgstr "Medium export"
+
+#: ../../importer.rst:15 2cfcdf575387417bae3a9938aa55b0e6
+msgid "Tumblr API"
+msgstr "Tumblr API"
+
+#: ../../importer.rst:16 42233d68a4bc46339b284681bdbdd19c
+msgid "WordPress XML export"
+msgstr "WordPress XML export"
+
+#: ../../importer.rst:17 0170dad08a80435b99a39ccaf887c5bb
+msgid "RSS/Atom feed"
+msgstr "RSS/Atom feed"
+
+#: ../../importer.rst:19 077a8220f4a84dd297ec5aa7cff15a24
+msgid ""
+"The conversion from HTML to reStructuredText or Markdown relies on "
+"`Pandoc`_. For Dotclear, if the source posts are written with Markdown "
+"syntax, they will not be converted (as Pelican also supports Markdown)."
+msgstr ""
+"从HTML转换到reStructuredText或Markdown是依赖 `Pandoc`_ "
+"完成的。对于Dotclear,若原帖子是由Markdown语法写的,则无需转换"
+"(因为Pelican本就支持Markdown)。"
+
+#: ../../importer.rst:25 e9b94b6029204b82b009d3ef23c19814
+msgid ""
+"Unlike Pelican, Wordpress supports multiple categories per article. These"
+" are imported as a comma-separated string. You have to resolve these "
+"manually, or use a plugin such as `More Categories`_ that enables "
+"multiple categories per article."
+msgstr ""
+"和Pelican不同,在Wordpress中可以将一篇文章同时放在多个分类中。在导入时,各个分类"
+"会以逗号分隔,你必须自己手动进行处理。或者也可以使用例如 `More Categories`_ "
+"这样的插件,使得文章可以同时存在于多个分类中。"
+
+#: ../../importer.rst:32 f7add19b68754b6e8a617a1d50dee759
+msgid ""
+"Imported pages may contain links to images that still point to the "
+"original site. So you might want to download those images into your local"
+" content and manually re-link them from the relevant pages of your site."
+msgstr ""
+"要导入的内容中可能会包含指向原站点的图片链接,你可能希望将他们全部下载下来,然后再"
+"重新手动调整这些链接。"
+
+#: ../../importer.rst:37 22cc1a514c4f42efbcf9afc3d987c42e
+msgid "Dependencies"
+msgstr "依赖"
+
+#: ../../importer.rst:39 6139199770a24fc7af7ca7e556d18d5f
+msgid ""
+"``pelican-import`` has some dependencies not required by the rest of "
+"Pelican:"
+msgstr ""
+"``pelican-import`` 需要用到一些其他依赖,这些依赖只会被 ``pelican-import`` 用到:"
+
+#: ../../importer.rst:41 0e8eb04bb07f4752880b873e73e7f7e5
+msgid ""
+"*BeautifulSoup4* and *lxml*, for WordPress and Dotclear import. Can be "
+"installed like any other Python package (``pip install BeautifulSoup4 "
+"lxml``)."
+msgstr ""
+"为了能够导入WordPress和Dotclear的内容,需要 *BeautifulSoup4* 与 *lxml* 。"
+"安装方法与其他Python包相同( ``pip install BeautifulSoup4 lxml`` )"
+
+#: ../../importer.rst:44 7d31c1ad4ecb4014a3ef240436b9b3e1
+msgid "*Feedparser*, for feed import (``pip install feedparser``)."
+msgstr "为了能够导入订阅源,需要 *Feedparser* ( ``pip install feedparser`` )"
+
+#: ../../importer.rst:45 db7a18b1a4534a17956c9d030dddff56
+msgid ""
+"*Pandoc*, see the `Pandoc site`_ for installation instructions on your "
+"operating system."
+msgstr ""
+"还需要 *Pandoc* ,参照 `Pandoc官方网站`_ 进行安装。"
+
+#: ../../importer.rst:53 9952881aed104ef0ac82af5339e6b149
+msgid "Usage"
+msgstr "用法"
+
+#: ../../importer.rst:63 83dbe43e4d2e4d8eaf3e37724ac119e3
+msgid "Positional arguments"
+msgstr "位置参数"
+
+#: ../../importer.rst:65 4a12692744024752be75d82ed74d369d
+msgid "``input``"
+msgstr "``input``"
+
+#: ../../importer.rst:65 52f62f22221f4c3d964df5aced3d2a2b
+msgid "The input file to read"
+msgstr "需要读取的输入文件"
+
+#: ../../importer.rst:66 acc46432d5c14ea8a5e27e6ec2b84d18
+msgid "``api_key``"
+msgstr "``api_key``"
+
+#: ../../importer.rst:66 29dd358bf2fe49d8a218c56ca376f6a6
+msgid ""
+"(Tumblr only) api_key can be obtained from "
+"https://www.tumblr.com/oauth/apps"
+msgstr ""
+"(只会在Tumblr中用到)从 https://www.tumblr.com/oauth/apps 中获取到的api_key"
+
+#: ../../importer.rst:70 a81b90d51a9f4c28adc09038715cf5c2
+msgid "Optional arguments"
+msgstr "可选参数"
+
+#: ../../importer.rst:72 d4d5211b75aa4103b06ad7685368af06
+msgid "Show this help message and exit"
+msgstr "显示此帮助信息并退出 ``pelican-import`` "
+
+#: ../../importer.rst:73 a7bae87fe16644f4b5da7d32fdc05f95
+msgid "Blogger XML export (default: False)"
+msgstr "输入是否为Blogger XML格式(默认:False)"
+
+#: ../../importer.rst:74 e8c133125ed04120bcc3737fa2a0ba60
+msgid "Dotclear export (default: False)"
+msgstr "输入是否为Dotclear格式(默认:False)"
+
+#: ../../importer.rst:75 caffd159f92a4f36aadedec398823ac3
+msgid "Medium export (default: False)"
+msgstr "输入是否为Medium格式(默认:False)"
+
+#: ../../importer.rst:76 f1bcaccf8e2f43f6894f2f0540c9d7ba
+msgid "Tumblr API (default: False)"
+msgstr "输入是否为Tumblr API格式(默认:False)"
+
+#: ../../importer.rst:77 6131f8fa00294515a028f4bb1a3a3053
+msgid "WordPress XML export (default: False)"
+msgstr "输入是否为WordPress XML格式(默认:False)"
+
+#: ../../importer.rst:78 dad00ee0aebb4550acae995ecdbb622f
+msgid "Feed to parse (default: False)"
+msgstr "输入是否为订阅源格式(默认:False)"
+
+#: ../../importer.rst:80 0ca3cbbc57c64b5b88444ccde94f94ce
+msgid "Output path (default: content)"
+msgstr "输出路径(默认:content)"
+
+#: ../../importer.rst:82 baa2762a4ee745028e29865720ca299d
+msgid ""
+"Output markup format: ``rst``, ``markdown``, or ``asciidoc`` (default: "
+"``rst``)"
+msgstr ""
+"输出格式,可选值为: ``rst`` 、 ``markdown`` 、 ``asciidoc`` (默认: ``rst`` )"
+
+#: ../../importer.rst:84 53232a317a58422d8f070c245d3b7409
+msgid "Put files in directories with categories name (default: False)"
+msgstr "是否要将输出文件按分类名放到各文件夹中(默认:False)"
+
+#: ../../importer.rst:86 f72e1895d9fc4facb90ddffb53b31a0a
+msgid ""
+"Put files recognised as pages in \"pages/\" sub- directory (blogger and "
+"wordpress import only) (default: False)"
+msgstr ""
+"将识别为页面的文件放入“pages/” 子文件夹中(仅在blogger和wordpress中有用)(默认:False)"
+
+#: ../../importer.rst:89 3f9315af4f1e4ced8ece96fca71cb1e7
+msgid "Import only post from the specified author"
+msgstr "仅导入某个作者的帖子"
+
+#: ../../importer.rst:90 0b34125f0bb744b089fe77b86b3e50f7
+msgid ""
+"Strip raw HTML code that can't be converted to markup such as flash "
+"embeds or iframes (default: False)"
+msgstr ""
+"删除无法转换的HTML代码,例如嵌入的flash或iframe(默认:False)"
+
+#: ../../importer.rst:92 f899a119b708450bbd38913f813255c2
+msgid ""
+"Put wordpress custom post types in directories. If used with --dir-cat "
+"option directories will be created as \"/post_type/category/\" (wordpress"
+" import only)"
+msgstr ""
+"将wordpress中的自定义类型博文放到对应文件夹中。如果同时还使用了 --dir-cat 选项,"
+"输出转换后文件时会创建诸如“/post_type/category/” 的文件夹(只在wordpress中有效)"
+
+#: ../../importer.rst:95 627c041fab81460eafd4f5fe361bcd1a
+msgid ""
+"Download files uploaded to wordpress as attachments. Files will be added "
+"to posts as a list in the post header and links to the files within the "
+"post will be updated. All files will be downloaded, even if they aren't "
+"associated with a post. Files will be downloaded with their original path"
+" inside the output directory, e.g. \"output/wp-"
+"uploads/date/postname/file.jpg\". (wordpress import only) (requires an "
+"internet connection)"
+msgstr ""
+"下载作为附件上传到WordPress的文件。文件会以列表形式添加到帖子的开头,并且到这些"
+"文件的链接都会进行更新。另外,即使某些文件没有在任何帖子中用到,也同样会被下载。"
+"文件会被下载到输出文件夹下,并保持原始路径,例如"
+"“output/wp-uploads/date/postname/file.jpg” 。(仅在wordpress中有效,"
+"且需要互联网连接)"
+
+#: ../../importer.rst:104 11162d8c497b4108a38c2a60af4a4215
+msgid ""
+"Disable storing slugs from imported posts within output. With this "
+"disabled, your Pelican URLs may not be consistent with your original "
+"posts. (default: False)"
+msgstr ""
+"不保存导入推文的slug,会导致Pelican的URL和原推文不一致。(默认:False)"
+
+#: ../../importer.rst:109 f4f4b6e918d3498e927b59c5d0bae05a
+msgid "Blog name used in Tumblr API"
+msgstr "Tumblr API中使用的博客名"
+
+#: ../../importer.rst:113 16e0f9bd1c6e4b338673f1800e6a4995
+msgid "Examples"
+msgstr "例子"
+
+#: ../../importer.rst:115 0cf17b9fd72940c391a1bb8bf7de534b
+msgid "For Blogger::"
+msgstr "导入Blogger:"
+
+#: ../../importer.rst:119 3fc79daf9e9e4f5ba1a121faaabd0c9e
+msgid "For Dotclear::"
+msgstr "导入Dotclear:"
+
+#: ../../importer.rst:123 328ff8145b464fa2ab59505a8bc3236a
+msgid "For Medium::"
+msgstr "导入Medium:"
+
+#: ../../importer.rst:127 8ca5f721833142249b6d798efcb77458
+msgid ""
+"The Medium export is a zip file. Unzip it, and point this tool to the "
+"\"posts\" subdirectory. For more information on how to export, see "
+"https://help.medium.com/hc/en-us/articles/115004745787-Export-your-"
+"account-data."
+msgstr ""
+"Medium中导出的是一个zip文件。请先解压之,然后再将其中的“posts”子目录传给此工具。 "
+"https://help.medium.com/hc/en-us/articles/115004745787-Export-your-account-data "
+"中有更详细的导出指导。"
+
+#: ../../importer.rst:131 516a83a4d8cf4570a9a6fff416e5cf5a
+msgid "For Tumblr::"
+msgstr "导入Tumblr:"
+
+#: ../../importer.rst:135 8fcab620c0d44bb29a120d8d781f4daa
+msgid "For WordPress::"
+msgstr "导入WordPress:"
+
+#: ../../importer.rst:139 a929213eb21f4118b9adbb6199bd78ea
+msgid "For Medium (an example of using an RSS feed):"
+msgstr "导入Medium(例子中使用了RSS订阅源):"
+
+#: ../../importer.rst:141 5e23c5d167ef4db1994f4323ac3d120e
+msgid ""
+"$ python -m pip install feedparser $ pelican-import --feed "
+"https://medium.com/feed/@username"
+msgstr ""
+"$ python -m pip install feedparser $ pelican-import --feed "
+"https://medium.com/feed/@username"
+
+#: ../../importer.rst:146 b44dfe0f807049899c0560c6bf62c386
+msgid "The RSS feed may only return the most recent posts — not all of them."
+msgstr "RSS订阅源可能只会返回最新的帖子,而不是所有帖子。"
+
+#: ../../importer.rst:149 575426ff787d4647b3aa2469b8b52412
+msgid "Tests"
+msgstr "测试"
+
+#: ../../importer.rst:151 036d2119412b41f3a3cb69cec74ecc81
+msgid "To test the module, one can use sample files:"
+msgstr "可以使用下面的文件作为样例进行测试:"
+
+#: ../../importer.rst:153 482b30f9aab54717bb14218ae5fa8ea6
+msgid ""
+"for WordPress: https://www.wpbeginner.com/wp-themes/how-to-add-dummy-"
+"content-for-theme-development-in-wordpress/"
+msgstr ""
+"WordPress: https://www.wpbeginner.com/wp-themes/how-to-add-dummy-content-"
+"for-theme-development-in-wordpress/"
+
+#: ../../importer.rst:154 6cb1bd10d37e4993aabece8aaed20171
+msgid "for Dotclear: http://media.dotaddict.org/tda/downloads/lorem-backup.txt"
+msgstr "Dotclear: http://media.dotaddict.org/tda/downloads/lorem-backup.txt"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/index.po b/docs/locale/zh_CN/LC_MESSAGES/index.po
new file mode 100644
index 00000000..47773c0b
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/index.po
@@ -0,0 +1,134 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../index.rst:2 160b5c32c524404ba295da4e89124739
+msgid "Pelican |release|"
+msgstr "Pelican |release|"
+
+#: ../../index.rst:4 19170a80b4274f71b77062c7a6b90726
+msgid ""
+"Pelican is a static site generator, written in Python_. Highlights "
+"include:"
+msgstr ""
+"Pelican是一个用 Python_ 写的静态站点生成器,它有诸多亮点:"
+
+#: ../../index.rst:6 6ab42a346f2c46d789cd46655195f2d3
+msgid ""
+"Write your content directly with your editor of choice in "
+"reStructuredText_ or Markdown_ formats"
+msgstr ""
+"你可以直接在自己的编辑器中用 reStructuredText_ 或 Markdown_ 完成内容创作"
+
+#: ../../index.rst:8 dbd17888530e43ce8bdfc1594947032c
+msgid "Includes a simple CLI tool to (re)generate your site"
+msgstr "自带了一个简单的命令行工具,你可以用它来生成你的站点"
+
+#: ../../index.rst:9 2bbe72bda8db457a88f3d3a94d16cc0c
+msgid "Easy to interface with distributed version control systems and web hooks"
+msgstr "易于与分布式版本控制系统和webhook交互"
+
+#: ../../index.rst:10 24af69b083024f2a9c4f162d54fa57c6
+msgid "Completely static output is easy to host anywhere"
+msgstr "生成的站点是完全静态的,可以在任何主机上轻松地部署"
+
+#: ../../index.rst:12 1e2090f3f19d49a19a6c50524e4cd0b7
+msgid "Ready to get started? Check out the :doc:`Quickstart` guide."
+msgstr "准备好开始体验了吗?请查看 :doc:`快速入门` 指南。"
+
+#: ../../index.rst:15 481a352565e84c848e018de507fbe9af
+msgid "Features"
+msgstr "特性"
+
+#: ../../index.rst:17 6c7b5d9b43ca42f1b1df139e7f884d26
+msgid "Pelican’s feature highlights include:"
+msgstr "Pelican在特性上也有很多亮点:"
+
+#: ../../index.rst:19 464e5e8ea8324fab9c5496b317a6db97
+msgid ""
+"Articles (e.g., blog posts) and pages (e.g., \"About\", \"Projects\", "
+"\"Contact\")"
+msgstr ""
+"可以生成文章(例如博客推文)和页面(例如“关于”、“联系我们”、“项目”)"
+
+#: ../../index.rst:20 c7cc4fe6ea8145feb0ace7d0965e2634
+msgid "Integration with external services"
+msgstr "可以和外部服务集成"
+
+#: ../../index.rst:21 ceb2c8a629024157946eba53638d7eb1
+msgid "Site themes (created using Jinja2_ templates)"
+msgstr "可以使用主题(主题使用 Jinja2_ 模板引擎创建)"
+
+#: ../../index.rst:22 51c3defcba6c4d31a77c3aade6826f1a
+msgid "Publication of articles in multiple languages"
+msgstr "可以为同一篇文章发布多种语言版本"
+
+#: ../../index.rst:23 6f7cbfae94c54318a904e9725ce73677
+msgid "Generation of Atom and RSS feeds"
+msgstr "可以生成Atom和Rss订阅源"
+
+#: ../../index.rst:24 3d667d2ed98a489788f6c38a4e4a6752
+msgid "Code syntax highlighting"
+msgstr "可以渲染代码高亮"
+
+#: ../../index.rst:25 bf1a1f91b821464182471a3760a59d4f
+msgid "Import existing content from WordPress, Dotclear, or RSS feeds"
+msgstr "可以从WordPress、Dotclear或Rss订阅源导入已有的内容"
+
+#: ../../index.rst:26 bd82641c549645cb8b4cd3187800397c
+msgid "Fast rebuild times thanks to content caching and selective output writing"
+msgstr "得益于内容缓存和选择性生成设计,可以快速重新生成站点"
+
+#: ../../index.rst:27 8dec47d1ab13410c9b99db0709c860a3
+msgid "Extensible via a rich plugin ecosystem: `Pelican Plugins`_"
+msgstr "可扩展性强,有丰富的插件生态: `Pelican Plugins`_"
+
+#: ../../index.rst:30 c7e090d7d2e04ff1ac1844e56209d75b
+msgid "Why the name \"Pelican\"?"
+msgstr "为什么叫做“Pelican”?"
+
+#: ../../index.rst:32 8c31222af5e24ba69acb5dd07a5b5d56
+msgid ""
+"\"Pelican\" is an anagram for *calepin*, which means \"notebook\" in "
+"French. ;)"
+msgstr ""
+"“Pelican”是法语词笔记本 *calepin* 读音的回文。;)"
+
+#: ../../index.rst:35 188f72b2bb644f978180eba22009ebc6
+msgid "Source code"
+msgstr "源码"
+
+#: ../../index.rst:37 2c8804f173fb4aa8973fb4d2413c263b
+msgid "You can access the source code at: https://github.com/getpelican/pelican"
+msgstr "在这里可以获取Pelican的源码: https://github.com/getpelican/pelican"
+
+#: ../../index.rst:40 06ab21b7cde94cee92193199ddc69775
+msgid "How to get help, contribute, or provide feedback"
+msgstr "如何获取帮助、贡献内容或是提供反馈"
+
+#: ../../index.rst:42 7fdcc2bcaac04317a6f4114f1d9c327f
+msgid ""
+"See our :doc:`feedback and contribution submission guidelines "
+"`."
+msgstr ""
+"请查看文档 :doc:`反馈意见和贡献的提交指南 `。"
+
+#: ../../index.rst:45 3d15499d76e1489d8e8782c65f73bb29
+msgid "Documentation"
+msgstr "文档"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/install.po b/docs/locale/zh_CN/LC_MESSAGES/install.po
new file mode 100644
index 00000000..4bc2c10f
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/install.po
@@ -0,0 +1,244 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-25 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../install.rst:2 32d9c99d9171418c89daafbe7260daa9
+msgid "Installing Pelican"
+msgstr "安装Pelican"
+
+#: ../../install.rst:4 73ec02b650044be6bb17951f4a915075
+msgid ""
+"Pelican currently runs best on |min_python|; earlier versions of Python "
+"are not supported."
+msgstr ""
+"Pelican需要 |min_python| 以上版本的Python,不支持更低版本。"
+
+#: ../../install.rst:6 9134a5a1bd9a4f54a36a3da163d859d8
+msgid ""
+"You can install Pelican via several different methods. The simplest is "
+"via Pip_::"
+msgstr ""
+"有多种方法可以安装Pelican,最简单的就是通过 Pip_:"
+
+#: ../../install.rst:10 22d5948b07d14a13bc45aa14ef11e856
+msgid "Or, if you plan on using Markdown::"
+msgstr "如果您需要使用Markdown,请使用下面的命令安装:"
+
+#: ../../install.rst:14 b910f7faa2c84e5eb62fbd0fae2544d3
+msgid ""
+"(Keep in mind that some operating systems will require you to prefix the "
+"above command with ``sudo`` in order to install Pelican system-wide.)"
+msgstr ""
+"(在某些操作系统中,需要在命令前加 ``sudo`` 才能在整个系统上安装Pelican)"
+
+#: ../../install.rst:17 afb018b5d42e433e8107ca38dfcb545f
+msgid ""
+"While the above is the simplest method, the recommended approach is to "
+"create a virtual environment for Pelican via virtualenv_ before "
+"installing Pelican. Assuming you have virtualenv_ installed, you can then"
+" open a new terminal session and create a new virtual environment for "
+"Pelican::"
+msgstr ""
+"尽管上面是最简单的安装方法,但我们推荐使用虚拟环境 virtualenv_ 完成"
+"Pelican的安装。当您安装好 virtualenv_ 后,打开一个新的命令行并"
+"为Pelican创建一个虚拟环境:"
+
+#: ../../install.rst:26 7d981233f13e42b6b07fbd5fa58f69fc
+msgid ""
+"Once the virtual environment has been created and activated, Pelican can "
+"be installed via ``python -m pip install pelican`` as noted above. "
+"Alternatively, if you have the project source, you can install Pelican "
+"using the distutils method::"
+msgstr ""
+"当创建并激活虚拟环境后,使用之前提到过的命令 ``python -m pip install pelican`` "
+"就可以安装Pelican了。或者,如果您想要从源码安装,可以使用distutils方式:"
+
+#: ../../install.rst:33 c8109ae3e44541e18e713e39690009ae
+msgid ""
+"If you have Git installed and prefer to install the latest bleeding-edge "
+"version of Pelican rather than a stable release, use the following "
+"command::"
+msgstr ""
+"如果安装过Git,并且您希望安装Pelican的最最新版本(而不是稳定版),"
+"请使用下面的命令:"
+
+#: ../../install.rst:38 2ba389e93d084dea8b702336479a0470
+msgid ""
+"Once Pelican is installed, you can run ``pelican --help`` to see basic "
+"usage options. For more detail, refer to the :doc:`Publish` "
+"section."
+msgstr ""
+"当您安装好Pelican,可以执行 ``pelican --help`` 命令来查看一些基本用法。"
+"在 :doc:`发布站点` 章节中可以了解更多信息。"
+
+#: ../../install.rst:42 d1850a31cca24c5281cc7c9fd748b56b
+msgid "Optional packages"
+msgstr "可选包"
+
+#: ../../install.rst:44 8428281e15354c71a5aec92e9e0041b9
+msgid ""
+"If you plan on using `Markdown `_ as "
+"a markup format, you can install Pelican with Markdown support::"
+msgstr ""
+"如您希望使用 `Markdown `_ "
+"来写作,执行下面的命令来安装Markdown支持:"
+
+#: ../../install.rst:49 6dcdacecb0874afd8c88cbf814c522ba
+msgid ""
+"Typographical enhancements can be enabled in your settings file, but "
+"first the requisite `Typogrify `_ "
+"library must be installed::"
+msgstr ""
+"Pelican还支持排版增强,若您需要使用,请先安装 `Typogrify "
+"`_ 库,稍后您可以在设置文件中启用它。"
+
+#: ../../install.rst:56 d3ff6383ae9745bc9bfed85654086311
+msgid "Dependencies"
+msgstr "依赖"
+
+#: ../../install.rst:58 2dc22a3fa6c242bdb5b61005e1910d79
+msgid ""
+"When Pelican is installed, the following dependent Python packages should"
+" be automatically installed without any action on your part:"
+msgstr ""
+"当Pelican安装完成后,下面的所有Python依赖应该都会自动安装,"
+"无需另外做任何操作:"
+
+#: ../../install.rst:61 4c7a644a29b540869d69acd10e032039
+msgid ""
+"`feedgenerator `_, to generate "
+"the Atom feeds"
+msgstr ""
+"`feedgenerator `_,"
+"用于生成Atom feeds"
+
+#: ../../install.rst:63 365c8fb0938e4d9fbf78d110b05cb99f
+msgid "`jinja2 `_, for templating support"
+msgstr "`jinja2 `_,用于模板系统"
+
+#: ../../install.rst:64 5db63207e60c4997924c3baf8aec8524
+msgid "`pygments `_, for syntax highlighting"
+msgstr "`pygments `_,用于语法高亮"
+
+#: ../../install.rst:65 72bfb5fc2b514031a42952502746c100
+msgid ""
+"`docutils `_, for supporting "
+"reStructuredText as an input format"
+msgstr ""
+"`docutils `_,"
+"用于reStructuredText格式"
+
+#: ../../install.rst:67 d00ac0c26d884a2d9d7f02fa89491892
+msgid ""
+"`blinker `_, an object-to-object and "
+"broadcast signaling system"
+msgstr ""
+"`blinker `_,"
+"对象-对象的信号广播系统"
+
+#: ../../install.rst:69 0d317b007acf49fc879203fa8ffb4048
+msgid ""
+"`unidecode `_, for ASCII "
+"transliterations of Unicode text utilities"
+msgstr ""
+"`unidecode `_,"
+"用于将Unicode文本转为ASCII字符的音译"
+
+#: ../../install.rst:72 ded0aae575854f149bcf2ea9efa4ba21
+msgid ""
+"`MarkupSafe `_, for a markup-safe "
+"string implementation"
+msgstr ""
+"`MarkupSafe `_,"
+"用于转义字符的安全处理"
+
+#: ../../install.rst:74 eae7d8f6f84040339ccfef98e20502d8
+msgid ""
+"`python-dateutil `_, to read "
+"the date metadata"
+msgstr ""
+"`python-dateutil `_,"
+"用于读取日期相关的元数据"
+
+#: ../../install.rst:78 cd33ec4583574c5bb879f08813b9932c
+msgid "Upgrading"
+msgstr "更新升级"
+
+#: ../../install.rst:80 1513dd1e43564cb29da0a14988e0791d
+msgid ""
+"If you installed a stable Pelican release via Pip_ and wish to upgrade to"
+" the latest stable release, you can do so by adding ``--upgrade``::"
+msgstr ""
+"若是通过 Pip_ 安装了稳定版本的Pelican,可以通过在安装命令中"
+"添加 ``--upgrade`` 来升级到最新版:"
+
+#: ../../install.rst:85 fae6900b3acc41d4b7bb34c192fe4c08
+msgid ""
+"If you installed Pelican via distutils or the bleeding-edge method, "
+"simply perform the same step to install the most recent version."
+msgstr ""
+"若是通过distutils安装或是通过Git安装了测试版的Pelican"
+"重新进行一遍和安装时同样的步骤即可。"
+
+#: ../../install.rst:89 89392d36f81f4c7eb75e9a74d1795faa
+msgid "Kickstart your site"
+msgstr "启动网站"
+
+#: ../../install.rst:91 a8517a0fbbb1420297df214f50d8792d
+msgid ""
+"Once Pelican has been installed, you can create a skeleton project via "
+"the ``pelican-quickstart`` command, which begins by asking some questions"
+" about your site::"
+msgstr ""
+"Pelican安装完成后,通过 ``pelican-quickstart`` 命令创建项目的整体框架,"
+"在运行这个命令时,您需要输入一些与站点相关的信息:"
+
+#: ../../install.rst:97 50231ba4b02d4e868995bdacbd02b27d
+msgid ""
+"If run inside an activated virtual environment, ``pelican-quickstart`` "
+"will look for an associated project path inside "
+"``$VIRTUAL_ENV/.project``. If that file exists and contains a valid "
+"directory path, the new Pelican project will be saved at that location. "
+"Otherwise, the default is the current working directory. To set the new "
+"project path on initial invocation, use: ``pelican-quickstart --path "
+"/your/desired/directory``"
+msgstr ""
+"如果是在虚拟环境中执行 ``pelican-quickstart`` ,系统会自动在 "
+"``$VIRTUAL_ENV/.project`` 目录中查找这个命令。若这个这个命令存在"
+"并且路径是正确的,一个新的Pelican项目就会在目标位置创建。否则,"
+"会默认在当前的工作目录下创建这个项目。若要在初始化时指定项目路径,请使用 "
+"``pelican-quickstart --path /your/desired/directory``。"
+
+#: ../../install.rst:104 ea893addf15c47f182384509b1a3a2f7
+msgid ""
+"Once you finish answering all the questions, your project will consist of"
+" the following hierarchy (except for *pages* — shown in parentheses below"
+" — which you can optionally add yourself if you plan to create non-"
+"chronological content)::"
+msgstr ""
+"当您回答完所有问题后,项目就会成功创建。项目中会包含下述的一些层级结构"
+"(除了用括号括起来的 *pages*)。如果有一些内容不需要按时间排序,"
+"您可以将它们放在(pages)所在的位置:"
+
+#: ../../install.rst:118 7d13a0cc5ebd44159fddc8de68993fc7
+msgid ""
+"The next step is to begin to adding content to the *content* folder that "
+"has been created for you."
+msgstr ""
+"接下来就可以开始往 *content* 目录中添加自己创作的内容了。"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/internals.po b/docs/locale/zh_CN/LC_MESSAGES/internals.po
new file mode 100644
index 00000000..5fea5c46
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/internals.po
@@ -0,0 +1,172 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../internals.rst:2 5d90a7c7f9dd42b5ba1fdfc05c5e9c3c
+msgid "Pelican internals"
+msgstr "Pelican内部机制"
+
+#: ../../internals.rst:4 fa53597118244e8585b3b0a9fb4336c0
+msgid ""
+"This section describe how Pelican works internally. As you'll see, it's "
+"quite simple, but a bit of documentation doesn't hurt. :)"
+msgstr ""
+"这一节描述了Pelican的内部运行机制。你会发现,Pelican的内部其实并不复杂。 :)"
+
+#: ../../internals.rst:7 c9a34db098f34796b80ee62896702be2
+msgid ""
+"You can also find in the :doc:`report` section an excerpt of a report the"
+" original author wrote with some software design information."
+msgstr "你可以在 :doc:`report` 一节中找到原作者用软件设计相关内容报告的节选。"
+
+#: ../../internals.rst:13 ac2af84842574bef9a791b416e21834e
+msgid "Overall structure"
+msgstr "总体结构"
+
+#: ../../internals.rst:15 fb7aea45b8f74c9c877bf2640d47aaac
+msgid ""
+"What Pelican does is take a list of files and process them into some sort"
+" of output. Usually, the input files are reStructuredText and Markdown "
+"files, and the output is a blog, but both input and output can be "
+"anything you want."
+msgstr ""
+"Pelican做的事情其实很简单:获取一个文件列表,并将它们处理为某种输出。通常,输入文件是"
+"reStructuredText和Markdown文件,输出是一个博客,但事实上输入和输出都可以是你想要的"
+"任何内容。"
+
+#: ../../internals.rst:19 599649d1e9da4355ab02b50ea4fbdb19
+msgid "The logic is separated into different classes and concepts:"
+msgstr "系统的整体逻辑可以分为几个不同的类和概念:"
+
+#: ../../internals.rst:21 8ec0821a726e4ade8046921cc09b3ea3
+msgid ""
+"**Writers** are responsible for writing files: .html files, RSS feeds, "
+"and so on. Since those operations are commonly used, the object is "
+"created once and then passed to the generators."
+msgstr ""
+"**Writers** 负责完成 html、RSS订阅源等等内容的文件写入。因为这些操作都是比较常用的,"
+"这个类只会被创建一次,然后再传给Generators。"
+
+#: ../../internals.rst:25 63c9a61869884147a8752e9be188e0e9
+msgid ""
+"**Readers** are used to read from various formats (HTML, Markdown and "
+"reStructuredText for now, but the system is extensible). Given a file, "
+"they return metadata (author, tags, category, etc.) and content (HTML-"
+"formatted)."
+msgstr ""
+"**Readers** 用于读取不同格式的文件(目前支持HTML、Markdown、reStructuredText,"
+"但可以继续扩展)。向**Readers**输入一个文件,它会返回文档的元数据(作者、标签、"
+"分类等等)与HTML格式的文档正文内容。"
+
+#: ../../internals.rst:29 d9bc146ae213415b804cd93ebf43e340
+msgid ""
+"**Generators** generate the different outputs. For instance, Pelican "
+"comes with ``ArticlesGenerator`` and ``PageGenerator``. Given a "
+"configuration, they can do whatever they want. Most of the time, it's "
+"generating files from inputs."
+msgstr ""
+"**Generators** 用以生成不同的输出,Pelican自带了 ``ArticlesGenerator`` 和 "
+"``PageGenerator`` 。给定一套配置信息, **Generators** 可以做几乎任何事。"
+"但大多数情况下,它的工作就是从输入生成文件。"
+
+#: ../../internals.rst:34 49ef39e8677a4529a3ee226faae1526b
+msgid ""
+"Pelican also uses templates, so it's easy to write your own theme. The "
+"syntax is `Jinja2 `_ and is very "
+"easy to learn, so don't hesitate to jump in and build your own theme."
+msgstr ""
+"Pelican使用了模板引擎,因此可以较为简单地编写自定义主题。模板语法使用的是易于学习的 "
+"`Jinja2 `_ ,因此快去构建你自己的主题吧。"
+
+#: ../../internals.rst:39 1aef766f93d549afa332fad4278c4063
+msgid "How to implement a new reader?"
+msgstr "如何实现一个新的reader?"
+
+#: ../../internals.rst:41 abbbfc19ccea4e3ea3716179981e3c1d
+msgid ""
+"Is there an awesome markup language you want to add to Pelican? Well, the"
+" only thing you have to do is to create a class with a ``read`` method "
+"that returns HTML content and some metadata."
+msgstr ""
+"若是希望为Pelican添加一个标记语言,只需要创建一个类,实现 ``read`` 方法,并在其中"
+"返回元数据和以HTML表示的正文内容。"
+
+#: ../../internals.rst:45 1e9fc1bcc9444db4b751f1c621280a32
+msgid "Take a look at the Markdown reader::"
+msgstr "可以看一看Markdown的reader:"
+
+#: ../../internals.rst:71 cbc4f49384964be3a0a68b1083100839
+msgid "Simple, isn't it?"
+msgstr "是不是很简单呢?"
+
+#: ../../internals.rst:73 02643c7e485d49e39344570ba5639a60
+msgid ""
+"If your new reader requires additional Python dependencies, then you "
+"should wrap their ``import`` statements in a ``try...except`` block. "
+"Then inside the reader's class, set the ``enabled`` class attribute to "
+"mark import success or failure. This makes it possible for users to "
+"continue using their favourite markup method without needing to install "
+"modules for formats they don't use."
+msgstr ""
+"如果新创建的reader需要额外的Python依赖,应该把 ``import`` 放在 ``try...except`` "
+"块中。在reader类中,设置类属性 ``enabled`` 来标记import是否成功。这使得用户能"
+"继续使用他们喜欢的标记语言而无需安装用不到的模块。"
+
+#: ../../internals.rst:80 02deeeac368b4dbc8c7b1025275d5bd5
+msgid "How to implement a new generator?"
+msgstr "如何实现一个新的generator?"
+
+#: ../../internals.rst:82 f7e5c28efbdb40c0bac7b985e8264310
+msgid ""
+"Generators have two important methods. You're not forced to create both; "
+"only the existing ones will be called."
+msgstr ""
+"generator有两个重要方法。不一定两个都要创建,若只创建了一个,就会自动调用存在的方法。"
+
+#: ../../internals.rst:85 01f2801461e043e7882167907e337d2c
+msgid ""
+"``generate_context``, that is called first, for all the generators. Do "
+"whatever you have to do, and update the global context if needed. This "
+"context is shared between all generators, and will be passed to the "
+"templates. For instance, the ``PageGenerator`` ``generate_context`` "
+"method finds all the pages, transforms them into objects, and populates "
+"the context with them. Be careful *not* to output anything using this "
+"context at this stage, as it is likely to change by the effect of other "
+"generators."
+msgstr ""
+"``generate_context`` 会优先被调用,其中可以完成任何你想要做的事,如果需要的话,还要"
+"更新全局上下文。全局上下文会在所有generator间共享,并在之后传给模板。例如 "
+"``PageGenerator`` 的 ``generate_context`` 方法会找寻所有页面,并将他们转换为对象,"
+"再将上下文传入其中。注意,请 *不要* 在此阶段使用该上下文输出任何内容,因为其他"
+"generator还会继续影响上下文。"
+
+#: ../../internals.rst:93 3241d04af8944c48bf162963a774000c
+msgid ""
+"``generate_output`` is then called. And guess what is it made for? Oh, "
+"generating the output. :) It's here that you may want to look at the "
+"context and call the methods of the ``writer`` object that is passed as "
+"the first argument of this function. In the ``PageGenerator`` example, "
+"this method will look at all the pages recorded in the global context and"
+" output a file on the disk (using the writer method ``write_file``) for "
+"each page encountered."
+msgstr ""
+"``generate_output`` 会在 ``generate_context`` 之后被调用,用于生成要输出的内容。"
+"此时就需要使用上下文并调用 ``writer`` 对象的方法,此 ``writer`` 就是传入 "
+"``generate_output`` 方法的第一个参数。``PageGenerator`` 的 ``generate_output`` "
+"方法中,会使用writer的 ``write_file`` 方法为全局上下文中的每一个页面输出一个文件。"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/pelican-themes.po b/docs/locale/zh_CN/LC_MESSAGES/pelican-themes.po
new file mode 100644
index 00000000..bceef808
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/pelican-themes.po
@@ -0,0 +1,206 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../pelican-themes.rst:2 1fce54d5389b41f4a588e9b23b646aee
+msgid "pelican-themes"
+msgstr "pelican-themes"
+
+#: ../../pelican-themes.rst:7 6158b329ed7b469286405115e2ed7fa0
+msgid "Description"
+msgstr "简介"
+
+#: ../../pelican-themes.rst:9 3df74d6d079945f7a4e0062ed5ea3eed
+msgid ""
+"``pelican-themes`` is a command line tool for managing themes for "
+"Pelican. See :ref:`settings/themes` for settings related to themes."
+msgstr ""
+"``pelican-themes`` 是一个命令行工具,用于管理Pelican主题。有关主题的配置,"
+"请参考 :ref:`设置章节中的主题 ` 。"
+
+#: ../../pelican-themes.rst:14 03eb76faf4544c8dbf478752096c7d7c
+msgid "Usage"
+msgstr "用法"
+
+#: ../../pelican-themes.rst:16 d5dcdc6c26094f5695061f9c53633589
+msgid "pelican-themes [-h] [-l] [-i theme path [theme path ...]]"
+msgstr "pelican-themes [-h] [-l] [-i theme path [theme path ...]]"
+
+#: ../../pelican-themes.rst:17 99b7a21ca612425da217b72b8c0c9b64
+msgid "[-r theme name [theme name ...]]"
+msgstr "[-r theme name [theme name ...]]"
+
+#: ../../pelican-themes.rst:18 1f64db909173426dabee822aea3b269b
+msgid "[-s theme path [theme path ...]] [-v] [--version]"
+msgstr "[-s theme path [theme path ...]] [-v] [--version]"
+
+#: ../../pelican-themes.rst:21 63ef4d44a1db4176b4c3866671a93603
+msgid "Optional arguments:"
+msgstr "可选参数:"
+
+#: ../../pelican-themes.rst:24 348360945a0943ffa8122aad16bf0ec1
+msgid "Show the help and exit"
+msgstr "显示帮助信息并退出"
+
+#: ../../pelican-themes.rst:26 aaec8d28264b45b7aac617b7140b5b13
+msgid "Show the themes already installed"
+msgstr "显示已安装的主题"
+
+#: ../../pelican-themes.rst:28 c8d44b6ac6754f4e8e10a39848f042d0
+msgid "One or more themes to install"
+msgstr "安装一个或多个主题"
+
+#: ../../pelican-themes.rst:30 18077fbf428e476aa218464fb0f18d8d
+msgid "One or more themes to remove"
+msgstr "移除一个或多个主题"
+
+#: ../../pelican-themes.rst:32 e328d59886be45a6ae9530a0f2bea3ca
+msgid ""
+"Same as ``--install``, but create a symbolic link instead of copying the "
+"theme. Useful for theme development"
+msgstr ""
+"和 ``--install`` 相同,区别在于此选项仅会创建一个符号链接到给定的目录,"
+"而不会将主题完整拷贝。一般用于主题的开发"
+
+#: ../../pelican-themes.rst:35 481c7a32a5e6400d83c9e2e56e6b94a4
+msgid "Verbose output"
+msgstr "开启详细输出"
+
+#: ../../pelican-themes.rst:37 d7889dd20ac643ecad73e464ec4cfa55
+msgid "Print the version of this script"
+msgstr "显示此工具的版本信息"
+
+#: ../../pelican-themes.rst:42 5c3d3aabd5304e8f9a6f0593824f1da6
+msgid "Examples"
+msgstr "例子"
+
+#: ../../pelican-themes.rst:46 4d6ff63aae06482dbf22f41d4111b001
+msgid "Listing the installed themes"
+msgstr "列出已安装主题"
+
+#: ../../pelican-themes.rst:48 91a9e942ea36479999586426afead753
+msgid ""
+"With ``pelican-themes``, you can see the available themes by using the "
+"``-l`` or ``--list`` option:"
+msgstr ""
+"在 ``pelican-themes`` 中使用 ``-l`` 或 ``--list`` 选项,查看可用主题:"
+
+#: ../../pelican-themes.rst:62 7a2f7dc98fcc45cabc4639576d503c28
+msgid ""
+"In this example, we can see there are three themes available: "
+"``notmyidea``, ``simple``, and ``two-column``."
+msgstr ""
+"在上面的例子中,可以看到有三个主题可供使用: ``notmyidea`` 、 "
+"``simple`` 、和 ``two-column`` 。"
+
+#: ../../pelican-themes.rst:65 8c03dfa908114d92b8a9aeb6673555ce
+msgid ""
+"``two-column`` is followed by an ``@`` because this theme is not copied "
+"to the Pelican theme path, but is instead just linked to it (see "
+"`Creating symbolic links`_ for details about creating symbolic links)."
+msgstr ""
+"主题 ``two-column`` 后有一个 ``@`` ,这是因为该主题没有被拷贝到Pelican的主题"
+"路径下,而只是为其创建了一个符号链接 (详见 `创建符号链接`_ )。"
+
+#: ../../pelican-themes.rst:69 bc91e8c3ff4a44dd9234d0ab186d8515
+msgid ""
+"Note that you can combine the ``--list`` option with the ``-v`` or "
+"``--verbose`` option to get more verbose output, like this:"
+msgstr ""
+"当然,你可以将 ``--list`` 选项和 ``-v`` 或 ``--verbose`` 结合起来,从而"
+"得到更详细的输出:"
+
+#: ../../pelican-themes.rst:81 0b407ed71e6a4b428f5a582b58a47f3c
+msgid "Installing themes"
+msgstr "安装主题"
+
+#: ../../pelican-themes.rst:83 e95f78a5c3b844b9a6fd2924f455748f
+msgid ""
+"You can install one or more themes using the ``-i`` or ``--install`` "
+"option. This option takes as argument the path(s) of the theme(s) you "
+"want to install, and can be combined with the ``--verbose`` option:"
+msgstr ""
+"使用 ``-i`` 或 ``--install`` 选项可以安装一个或多个主题。此选项将一个"
+"或多个到达主题的路径作为参数,同样可以结合 ``--verbose`` 选项:"
+
+#: ../../pelican-themes.rst:103 5b20e90396564e08860b2b3a569e7166
+msgid "Removing themes"
+msgstr "移除主题"
+
+#: ../../pelican-themes.rst:105 2415bf89e3804c9dbdc34814b0132b8c
+msgid ""
+"The ``pelican-themes`` command can also remove themes from the Pelican "
+"themes path. The ``-r`` or ``--remove`` option takes as argument the "
+"name(s) of the theme(s) you want to remove, and can be combined with the "
+"``--verbose`` option."
+msgstr ""
+"``pelican-themes`` 命令同样可用于移除Pelican主题文件夹下的主题。 ``-r`` 或 "
+"``--remove`` 选项以一个或多个主题的名称为参数,同样也可以结合 ``--verbose`` "
+"选项使用。"
+
+#: ../../pelican-themes.rst:122 9ea5149543a648049444220a4041da69
+msgid "Creating symbolic links"
+msgstr "创建符号链接"
+
+#: ../../pelican-themes.rst:124 17cdf3146683485ea72db5fbd9c1f60a
+msgid ""
+"``pelican-themes`` can also install themes by creating symbolic links "
+"instead of copying entire themes into the Pelican themes path."
+msgstr ""
+"``pelican-themes`` 也可以通过创建符号链接来安装主题,如此便无需完整拷贝主题。"
+
+#: ../../pelican-themes.rst:127 1d2c60b41c374936a9986a852d50e898
+msgid ""
+"To symbolically link a theme, you can use the ``-s`` or ``--symlink``, "
+"which works exactly as the ``--install`` option:"
+msgstr ""
+"使用 ``-s`` 或 ``--symlink`` 选项来为主题创建符号链接,用法和 ``--install`` 选项相同:"
+
+#: ../../pelican-themes.rst:134 66707a8607f549199dca6f93586d2d87
+msgid ""
+"In this example, the ``two-column`` theme is now symbolically linked to "
+"the Pelican themes path, so we can use it, but we can also modify it "
+"without having to reinstall it after each modification."
+msgstr ""
+"在上面的例子中, ``two-column`` 主题就已经在Pelican主题目录下创建了符号链接,"
+"也可以正常使用。如此,当我们修改主题后就无需重新进行安装。"
+
+#: ../../pelican-themes.rst:138 93ec27a473b04bca9d2930a7cb6b609c
+msgid "This is useful for theme development:"
+msgstr "这对主题的开发是很有用的:"
+
+#: ../../pelican-themes.rst:155 66d808308aa64fc9afcef8bdf03bca8b
+msgid "Doing several things at once"
+msgstr "同时执行多个操作"
+
+#: ../../pelican-themes.rst:157 ace10a2c2f4d4adab9ade60631e82c38
+msgid ""
+"The ``--install``, ``--remove`` and ``--symlink`` options are not "
+"mutually exclusive, so you can combine them in the same command line to "
+"do more than one operation at time, like this:"
+msgstr ""
+"``--install`` 、 ``--remove`` 和 ``--symlink`` 可以同时使用,不会冲突,"
+"因此可以在同一行命令中同时做多个操作:"
+
+#: ../../pelican-themes.rst:169 e7adbac04b6a40fd986c02e834cc1756
+msgid ""
+"In this example, the theme ``notmyidea-cms`` is replaced by the theme "
+"``notmyidea-cms-fr``"
+msgstr ""
+"在上面的例子中,用 ``notmyidea-cms-fr`` 替换了 ``notmyidea-cms`` 主题。"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/plugins.po b/docs/locale/zh_CN/LC_MESSAGES/plugins.po
new file mode 100644
index 00000000..7b62744d
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/plugins.po
@@ -0,0 +1,711 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-26 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../plugins.rst:4 b1b40bca7d3748008eefe26806d5d5ef
+msgid "Plugins"
+msgstr "插件"
+
+#: ../../plugins.rst:6 42ca486828e4442a9d74216d0d8bb37d
+msgid ""
+"Beginning with version 3.0, Pelican supports plugins. Plugins are a way "
+"to add features to Pelican without having to directly modify the Pelican "
+"core."
+msgstr ""
+"Pelican从3.0版本开始支持插件。通过插件,不必直接修改Pelican的核心代码就可以给"
+"Pelican添加新功能。"
+
+#: ../../plugins.rst:10 6bb8ab4cb7eb44ddb1ed4734f47f6781
+msgid "How to use plugins"
+msgstr "如何使用插件"
+
+#: ../../plugins.rst:12 822e0bd7ce2f4433a7c39b3accde01a1
+msgid ""
+"Starting with version 4.5, Pelican moved to a new plugin structure "
+"utilizing namespace packages that can be easily installed via Pip_. "
+"Plugins supporting this structure will install under the namespace "
+"package ``pelican.plugins`` and can be automatically discovered by "
+"Pelican. To see a list of Pip-installed namespace plugins that are active"
+" in your environment, run::"
+msgstr ""
+"Pelican从4.5版本开始使用了一种全新的插件结构,利用了命名空间包,"
+"并且可以轻松地通过 Pip_ 进行安装。支持此结构地插件都会被安装在命名空间包 "
+"``pelican.plugins`` 下,因此Pelican可以自动发现他们。下面的命令可以用于"
+"查看环境中用Pip安装的所有插件:"
+
+#: ../../plugins.rst:20 2b59c5d107dc4b118dc76116910e9495
+msgid ""
+"If you leave the ``PLUGINS`` setting as default (``None``), Pelican will "
+"automatically discover namespace plugins and register them. If, on the "
+"other hand, you specify a ``PLUGINS`` setting as a list of plugins, this "
+"auto-discovery will be disabled. At that point, only the plugins you "
+"specify will be registered, and you must explicitly list any namespace "
+"plugins as well."
+msgstr ""
+"若将 ``PLUGINS`` 配置项设为默认的 ``None`` ,Pelican会自动发现命名空间中的"
+"插件并且将他们全部加载;若你在 ``PLUGINS`` 设置项中指定了一系列的插件,"
+"Pelican就不会去自动发现插件,也就是说,你需要显式地指定所有要使用的插件。"
+
+#: ../../plugins.rst:26 52d1968196294569a478931f7022e686
+msgid ""
+"If you are using the ``PLUGINS`` setting, you can specify plugins in two "
+"ways. The first method specifies plugins as a list of strings. Namespace "
+"plugins can be specified either by their full names "
+"(``pelican.plugins.myplugin``) or by their short names (``myplugin``)::"
+msgstr ""
+"在配置 ``PLUGINS`` 时,有两种方式。一是用字符串列表指定插件的名称,可以是包含"
+"命名空间的完整名称(例如 ``pelican.plugins.myplugin`` ),也可以是简短名称"
+"( ``myplugin``):"
+
+#: ../../plugins.rst:35 b2c75e52e66e4000968e744ffa4b89a9
+msgid ""
+"Alternatively, you can import them in your settings file and pass the "
+"modules::"
+msgstr ""
+"二是在设置文件中先import进来,再将import进的模块放在 ``PLUGINS`` 设置项中:"
+
+#: ../../plugins.rst:43 88af9139373f4cd89fa5b958196c9448
+msgid ""
+"When experimenting with different plugins (especially the ones that deal "
+"with metadata and content) caching may interfere and the changes may not "
+"be visible. In such cases disable caching with ``LOAD_CONTENT_CACHE = "
+"False`` or use the ``--ignore-cache`` command-line switch."
+msgstr ""
+"在尝试不同的插件时(尤其是那些处理元数据和内容的插件),缓存可能会相互干扰,"
+"一些更改不会生效。发生这种情况时,就需要通过设置 ``LOAD_CONTENT_CACHE = False`` "
+"或使用 ``--ignore-cache`` 命令行选项禁用缓存。"
+
+#: ../../plugins.rst:48 d0e3cd59052c4a7d995fb5e1e15d9799
+msgid ""
+"If your plugins are not in an importable path, you can specify a list of "
+"paths via the ``PLUGIN_PATHS`` setting. As shown in the following "
+"example, paths in the ``PLUGIN_PATHS`` list can be absolute or relative "
+"to the settings file::"
+msgstr ""
+"如果插件处于无法直接进行import的路径,可以在 ``PLUGIN_PATHS`` 配置项中指定这些路径。"
+"如下例所示, ``PLUGIN_PATHS`` 中的路径可以是绝对的,也可以是相对于设置文件的:"
+
+#: ../../plugins.rst:56 4c3de952a8514e5caea402392b911f0b
+msgid "Where to find plugins"
+msgstr "在哪儿下载插件"
+
+#: ../../plugins.rst:57 16173c9dceb0409f89964412dd7e71e9
+msgid ""
+"Namespace plugins can be found in the `pelican-plugins organization`_ as "
+"individual repositories. Legacy plugins are located in the `pelican-"
+"plugins repository`_ and will be gradually phased out in favor of the "
+"namespace versions."
+msgstr ""
+"新的命名空间插件可以在GitHub的 `pelican-plugins 组织`_ 中找到,每个插件都是"
+"一个独立的仓库。而老的插件则可以在GitHub的 `pelican-plugins 仓库`_ 中找到。"
+"这些老的插件会逐步淘汰并转移到新的命名空间版本。"
+
+#: ../../plugins.rst:65 a30a9862112b47128f6e7b28c6836f27
+msgid ""
+"Please note that while we do our best to review and maintain these "
+"plugins, they are submitted by the Pelican community and thus may have "
+"varying levels of support and interoperability."
+msgstr ""
+"请注意,尽管我们尽全力审查和维护这些插件,但这些插件是Pelican社区提交的,"
+"因此支持性和互操作性程度各不相同。"
+
+#: ../../plugins.rst:70 f4e140c61c0f45ed8ac53dca3b05b1f1
+msgid "How to create plugins"
+msgstr "如何创建插件"
+
+#: ../../plugins.rst:72 43013c6cf4f34ca09205e8dab0b9fa6d
+msgid ""
+"Plugins are based on the concept of signals. Pelican sends signals, and "
+"plugins subscribe to those signals. The list of available signals is "
+"documented in a subsequent section."
+msgstr ""
+"插件是基于信号这一概念的。Pelican会发送信号,插件则订阅这些信号。可用的信号"
+"在下一节会贴出来。"
+
+#: ../../plugins.rst:76 5377a966ab114a29acb61f79eadc632b
+msgid ""
+"The only rule to follow for plugins is to define a ``register`` callable,"
+" in which you map the signals to your plugin logic. Let's take a simple "
+"example::"
+msgstr ""
+"对于插件来说,唯一需要遵循的规则就是一定要定义一个可调用的 ``register`` ,"
+"在 ``register`` 中需要将信号映射到插件逻辑上。下面是一个简单的例子:"
+
+#: ../../plugins.rst:93 2217318326524c62804ec94e55a4ca20
+msgid ""
+"Signal receivers are weakly-referenced and thus must not be defined "
+"within your ``register`` callable or they will be garbage-collected "
+"before the signal is emitted."
+msgstr ""
+"信号接收器在Pelican中是弱引用的,因此不能将它定义在可调用的 ``register`` 中,"
+"否则接收器在信号发送之前就会被回收。"
+
+#: ../../plugins.rst:97 6731cc78478a46c5a0cb51a8cd477318
+msgid ""
+"If multiple plugins connect to the same signal, plugins will be executed "
+"in the order they are connected. With ``PLUGINS`` setting, order will be "
+"as defined in the setting. If you rely on auto-discovered namespace "
+"plugins, no ``PLUGINS`` setting, they will be connected in the same order"
+" they are discovered (same order as ``pelican-plugins`` output). If you "
+"want to specify the order explicitly, disable auto-discovery by defining "
+"``PLUGINS`` in the desired order."
+msgstr ""
+"如果多个插件关联到同一个信号,插件将按照它们关联的前后顺序执行。但若设置了 "
+"``PLUGINS`` 配置项会以此配置项中的顺序为准。如果您使用了无需PLUGINS设置的新版"
+"命名空间插件,它们将按照被探测到的顺序进行连接(与 pelican-plugins 输出的顺序相同)。"
+
+#: ../../plugins.rst:105 6dad534cc0014b78a3638a91cc4a1120
+msgid "Namespace plugin structure"
+msgstr "命名空间插件的结构"
+
+#: ../../plugins.rst:107 aa6f290c3f4d42558b684d0e3487af95
+msgid ""
+"Namespace plugins must adhere to a certain structure in order to function"
+" properly. They need to be installable (i.e. contain ``setup.py`` or "
+"equivalent) and have a folder structure as follows::"
+msgstr ""
+"命名空间插件必须遵循特定的结构才能正常工作。这些插件需要是可安装的"
+"(即包含 ``setup.py`` 或其他等效文件),并且遵循下述文件夹结构:"
+
+#: ../../plugins.rst:120 b8d73cfdb5f042cca1705f97d693263d
+msgid ""
+"It is crucial that ``pelican`` or ``pelican/plugins`` folder **not** "
+"contain an ``__init__.py`` file. In fact, it is best to have those "
+"folders empty besides the listed folders in the above structure and keep "
+"your plugin related files contained solely in the "
+"``pelican/plugins/myplugin`` folder to avoid any issues."
+msgstr ""
+"非常关键的一点就是, ``pelican`` 和 ``pelican/plugins`` 文件夹下都 **不能** 包含 "
+"``__init__.py`` 文件。事实上,这两个文件夹下最好是只有上面列出的文件夹,"
+"并且保证与插件相关的文件都仅包含在 ``pelican/plugins/myplugin`` 文件夹中,"
+"以避免奇奇怪怪的问题。"
+
+#: ../../plugins.rst:126 c3f08ae8c0d7415098157bbd1c99ce08
+msgid ""
+"To easily set up the proper structure, a `cookiecutter template for "
+"plugins`_ is provided. Refer to that project's README for instructions on"
+" how to use it."
+msgstr ""
+"为了让大家更容易就能建立正确的结构,我们为插件提供了一个 `cookiecutter模板`_ ,"
+"使用方法参考此项目README文件中的指示即可。"
+
+#: ../../plugins.rst:132 c2321eec3dc84224918172c5040a259f
+msgid "List of signals"
+msgstr "信号列表"
+
+#: ../../plugins.rst:134 78c4cfefae7e412f8f6287da2e3c8d34
+msgid "Here is the list of currently implemented signals:"
+msgstr "下面是目前已经实现了的信号:"
+
+#: ../../plugins.rst:137 7a3c3b8b0f114d54b497ab77b09dc558
+msgid "Signal"
+msgstr "信号"
+
+#: ../../plugins.rst:137 781b5c11f87f43b9ba4b3e75bee696d0
+msgid "Arguments"
+msgstr "参数"
+
+#: ../../plugins.rst:137 df7d14950fed44f4a4b93908aed36060
+msgid "Description"
+msgstr "描述"
+
+#: ../../plugins.rst:139 598901e7cb5b49ac9acb5f148bf7c0e7
+msgid "initialized"
+msgstr "initialized"
+
+#: ../../plugins.rst:139 ../../plugins.rst:140 ../../plugins.rst:158
+#: ../../plugins.rst:161 4cedbf9ee7fb4c7abe20e15e4ee1c7fb
+#: 704ff7e1ddfc4eb3bd7798d25df1e668 bc98001ef73d419b8f811bbb3d3a571a
+#: c9104ccaf84c48d98fafca001ec187e2
+msgid "pelican object"
+msgstr "pelican object"
+
+#: ../../plugins.rst:140 6f1a09178e2c44c9bda76ed0c0025bef
+msgid "finalized"
+msgstr "finalized"
+
+#: ../../plugins.rst:140 175a1d1ab8374325812a00cfd581e54e
+msgid ""
+"invoked after all the generators are executed and just before pelican "
+"exits useful for custom post processing actions, such as: - minifying "
+"js/css assets. - notify/ping search engines with an updated sitemap."
+msgstr ""
+"所有generator执行完成后调用,即pelican退出之前。这对于自定义后处理操作是"
+"非常有用的,例如可以简化js/css资源、向搜索引擎告知更新后的sitemap。"
+
+#: ../../plugins.rst:144 8d390b6db281423d92a4d7bd4921b4b4
+msgid "generator_init"
+msgstr "generator_init"
+
+#: ../../plugins.rst:144 fef4d6e70a4c4365be408a5f1579135c
+msgid "generator"
+msgstr "generator"
+
+#: ../../plugins.rst:144 dbe5ff1590dc4df38cb8fd234708c7bd
+msgid "invoked in the Generator.__init__"
+msgstr "在Generator.__init__中调用"
+
+#: ../../plugins.rst:145 0324812d14d9452fbf28c286c2a10834
+msgid "all_generators_finalized"
+msgstr "all_generators_finalized"
+
+#: ../../plugins.rst:145 f6170ebf34b247868d149f0efca462b3
+msgid "generators"
+msgstr "generators"
+
+#: ../../plugins.rst:145 d67dff93c28146498074abbf3aeb5103
+msgid "invoked after all the generators are executed and before writing output"
+msgstr "在所有generator执行完后,写入输出内容前调用,"
+
+#: ../../plugins.rst:146 0e9feed7804b4bbdb23711f9d6ad4f40
+msgid "readers_init"
+msgstr "readers_init"
+
+#: ../../plugins.rst:146 f0de00423c104ecd8e60fb3450b534b4
+msgid "readers"
+msgstr "readers"
+
+#: ../../plugins.rst:146 b554b35806e34e51bc5ab974fb517541
+msgid "invoked in the Readers.__init__"
+msgstr "在Readers.__init__中调用"
+
+#: ../../plugins.rst:147 ../../plugins.rst:201 003cdeb23b67433e8cf70c600a42e8e4
+#: 7f4a2f6665064a16bcd1b7ea347f5b49
+msgid "article_generator_context"
+msgstr "article_generator_context"
+
+#: ../../plugins.rst:147 8997b3fd1a8d4efb86245916e50c31b9
+msgid "article_generator, metadata"
+msgstr "article_generator, metadata"
+
+#: ../../plugins.rst:148 ../../plugins.rst:203 4496df152e48410995ae35f73e3ce0e9
+#: f46672e3f919441ba2486f9641752913
+msgid "article_generator_preread"
+msgstr "article_generator_preread"
+
+#: ../../plugins.rst:148 ../../plugins.rst:150 ../../plugins.rst:151
+#: ../../plugins.rst:154 3408ba823f14463196f2296480e25c7d
+#: 43b073d3f3ad4a2ba3d0c18447cb7cf6 c776a7323f0a41babb44daf3abfd6b85
+#: f47ca0a3f9654ed4b7653fd946b2d9b6
+msgid "article_generator"
+msgstr "article_generator"
+
+#: ../../plugins.rst:148 94e2a57c5b074d068f051d5de850060c
+msgid ""
+"invoked before a article is read in ArticlesGenerator.generate_context; "
+"use if code needs to do something before every article is parsed"
+msgstr ""
+"在ArticlesGenerator.generate_context读取文章之前调用;若代码需要在解析每篇文章前"
+"执行某些操作,就可以使用此信号。"
+
+#: ../../plugins.rst:150 c58f32123f234e6cafa42aa4ede5bf73
+msgid "article_generator_init"
+msgstr "article_generator_init"
+
+#: ../../plugins.rst:150 10d3585dc8f94d978643a9c2dc9219a9
+msgid "invoked in the ArticlesGenerator.__init__"
+msgstr "在ArticlesGenerator.__init__中调用"
+
+#: ../../plugins.rst:151 93ec423e266b4ba9b941a5826e290fec
+msgid "article_generator_pretaxonomy"
+msgstr "article_generator_pretaxonomy"
+
+#: ../../plugins.rst:151 27290d55819e4bfabe1624059956258f
+msgid ""
+"invoked before categories and tags lists are created useful when e.g. "
+"modifying the list of articles to be generated so that removed articles "
+"are not leaked in categories or tags"
+msgstr ""
+"在创建类别和标签列表之前调用。例如,当需要变更要生成的文章列表时可以使用,"
+"如此可以避免一些已移除文章在分类或标签列表中泄露。"
+
+#: ../../plugins.rst:154 ../../plugins.rst:202 12c99acda2ac45debe4fc574a246fc63
+#: f3bfb220e59d473bb27601c16f5a1625
+msgid "article_generator_finalized"
+msgstr "article_generator_finalized"
+
+#: ../../plugins.rst:154 4cb8ed5b4701426b8e1707c6c6b0d48f
+msgid "invoked at the end of ArticlesGenerator.generate_context"
+msgstr "在ArticlesGenerator.generate_context的最后调用"
+
+#: ../../plugins.rst:155 c19a632018d44ad2b72d5cf6b7cc9c14
+msgid "article_generator_write_article"
+msgstr "article_generator_write_article"
+
+#: ../../plugins.rst:155 9da20e77d40b45e292ae994fb0fbe97c
+msgid "article_generator, content"
+msgstr "article_generator, content"
+
+#: ../../plugins.rst:155 a2d5bc3f72b64e47bcaccff3bf27dec2
+msgid "invoked before writing each article, the article is passed as content"
+msgstr "在写入每篇文章前调用,文章以内容的形式作为参数传入。"
+
+#: ../../plugins.rst:156 0db965f5b99f49e48fc1db531c139f13
+msgid "article_writer_finalized"
+msgstr "article_writer_finalized"
+
+#: ../../plugins.rst:156 c6af98478be14eb283bb95e7b6a3118c
+msgid "article_generator, writer"
+msgstr "article_generator, writer"
+
+#: ../../plugins.rst:156 c48e1152864c4249886f3c7ed4ece85b
+msgid ""
+"invoked after all articles and related pages have been written, but "
+"before the article generator is closed."
+msgstr ""
+"在所有文章及相关联页面写入完成后,在文章generator关闭前调用。"
+
+#: ../../plugins.rst:158 f6af27fc844d43779d581cb4383b97ed
+msgid "get_generators"
+msgstr "get_generators"
+
+#: ../../plugins.rst:158 b41e27f19c47478a8ece4f43a685f6be
+msgid ""
+"invoked in Pelican.get_generator_classes, can return a Generator, or "
+"several generators in a tuple or in a list."
+msgstr ""
+"在Pelican.get_generator_classes中调用,可以返回一个Generator,也可以以一个"
+"元组或列表的形式返回多个generator。"
+
+#: ../../plugins.rst:161 f23075094c4f46958de609a44850eb6d
+msgid "get_writer"
+msgstr "get_writer"
+
+#: ../../plugins.rst:161 365671a73e17434f90973ee8e632fa32
+msgid "invoked in Pelican.get_writer, can return a custom Writer."
+msgstr "在Pelican.get_writer前调用,可以返回一个自定义Writer。"
+
+#: ../../plugins.rst:163 ../../plugins.rst:204 299eef53e530489a9e7366042919059f
+#: 917cc78965d84285bc832cecf181ce55
+msgid "page_generator_context"
+msgstr "page_generator_context"
+
+#: ../../plugins.rst:163 26f64e1dbe854ca287aa0f59b269477c
+msgid "page_generator, metadata"
+msgstr "page_generator, metadata"
+
+#: ../../plugins.rst:164 ../../plugins.rst:205 c2ec4e60dda142569cdcfe5a311b21a5
+#: fcd417f63054406ea7869a2a945dc819
+msgid "page_generator_preread"
+msgstr "page_generator_preread"
+
+#: ../../plugins.rst:164 ../../plugins.rst:166 ../../plugins.rst:167
+#: 89c2d7a279604926a290c2665fe8082a 98ab9a5bc2804442a217233f4ab8a003
+#: fca779509f1742e99e3d10a6602561c9
+msgid "page_generator"
+msgstr "page_generator"
+
+#: ../../plugins.rst:164 295fe11e61ba4f80a145ce06a1ffc777
+msgid ""
+"invoked before a page is read in PageGenerator.generate_context; use if "
+"code needs to do something before every page is parsed."
+msgstr ""
+"在PageGenerator.generate_context读取页面前调用,若代码需要在解析每个页面前"
+"执行某些操作,就可以使用此信号。"
+
+#: ../../plugins.rst:166 ../../plugins.rst:207 4f2b1db9b6054af2b0fd0545082bcafd
+#: db8ee3e356d84758b427d9f29d034000
+msgid "page_generator_init"
+msgstr "page_generator_init"
+
+#: ../../plugins.rst:166 1d4e2e940e0f4dd5a151519aea710454
+msgid "invoked in the PagesGenerator.__init__"
+msgstr "在PagesGenerator.__init__中调用"
+
+#: ../../plugins.rst:167 ../../plugins.rst:206 319e921c48474a43bbdac4bf43a688f2
+#: 5e9b33a48c51417fb5211824b0ad008d
+msgid "page_generator_finalized"
+msgstr "page_generator_finalized"
+
+#: ../../plugins.rst:167 019fa3fddf2e4725b978326f221c80bd
+msgid "invoked at the end of PagesGenerator.generate_context"
+msgstr "在PagesGenerator.generate_context的最后调用"
+
+#: ../../plugins.rst:168 0f77c3c609594768a0aaed6529260b97
+msgid "page_generator_write_page"
+msgstr "page_generator_write_page"
+
+#: ../../plugins.rst:168 0ca5fb200a254cff8529cb5d95e8e26e
+msgid "page_generator, content"
+msgstr "page_generator, content"
+
+#: ../../plugins.rst:168 164d45dac5ab4df8abd898c1466e186d
+msgid "invoked before writing each page, the page is passed as content"
+msgstr "在写入每个页面前调用,页面以内容形式作为参数传入"
+
+#: ../../plugins.rst:169 4780473ba6ae47998f891232f122b34a
+msgid "page_writer_finalized"
+msgstr "page_writer_finalized"
+
+#: ../../plugins.rst:169 6c516a5ae777406ca9ed7bf27b7124c7
+msgid "page_generator, writer"
+msgstr "page_generator, writer"
+
+#: ../../plugins.rst:169 e8978d0fb878427cbf686608c593aa67
+msgid ""
+"invoked after all pages have been written, but before the page generator "
+"is closed."
+msgstr "调用于所有页面写入完成后,在页面generator关闭前。"
+
+#: ../../plugins.rst:171 ../../plugins.rst:208 47bf9969c38b4fef9e15e9d7ea67630e
+#: d9a3d5d939d4499b9320ea15dbd3f26e
+msgid "static_generator_context"
+msgstr "static_generator_context"
+
+#: ../../plugins.rst:171 47064012c4e447f5a1f087a7af420f8f
+msgid "static_generator, metadata"
+msgstr "static_generator, metadata"
+
+#: ../../plugins.rst:172 ../../plugins.rst:209 7050e1889934465a8837ba65fa249118
+#: f45c31c591fd450badd89a7f87c6f991
+msgid "static_generator_preread"
+msgstr "static_generator_preread"
+
+#: ../../plugins.rst:172 ../../plugins.rst:175 ../../plugins.rst:176
+#: 1e99fc14855a4a2e8d1f4758e12792d9 45cdf5c2a8d049889b4315d1ea78f462
+#: b7ae37b94f2f44feb24ac32b0cdfa447
+msgid "static_generator"
+msgstr "static_generator"
+
+#: ../../plugins.rst:172 431017db31bf439f8d3fb5e16b020376
+msgid ""
+"invoked before a static file is read in StaticGenerator.generate_context;"
+" use if code needs to do something before every static file is added to "
+"the staticfiles list."
+msgstr ""
+"在StaticGenerator.generate_context读取静态文件前调用,若代码需要在每个静态文件"
+"加入静态文件列表前进行一些修改,就可以使用此信号。"
+
+#: ../../plugins.rst:175 2a380c26f2984e659ec36248a543a4c3
+msgid "static_generator_init"
+msgstr "static_generator_init"
+
+#: ../../plugins.rst:175 832447303775460c83743d831aa58290
+msgid "invoked in the StaticGenerator.__init__"
+msgstr "在StaticGenerator.__init__中调用"
+
+#: ../../plugins.rst:176 b01307445d54485a9036fb0f9619ff78
+msgid "static_generator_finalized"
+msgstr "static_generator_finalized"
+
+#: ../../plugins.rst:176 2f7e7e25668b44fc824bb39270c3de96
+msgid "invoked at the end of StaticGenerator.generate_context"
+msgstr "在StaticGenerator.generate_context的最后调用"
+
+#: ../../plugins.rst:177 2a34785767ee416dbe41a6aa1f7e4ab1
+msgid "content_object_init"
+msgstr "content_object_init"
+
+#: ../../plugins.rst:177 c41d8a8653a94d648b573b5c13db3954
+msgid "content_object"
+msgstr "content_object"
+
+#: ../../plugins.rst:177 379b6d76d2f14d05bf1502d2c55b125f
+msgid "invoked at the end of Content.__init__"
+msgstr "在Content.__init__的最后调用"
+
+#: ../../plugins.rst:178 10761aa6a1d54ee0a28e562bdacffebf
+msgid "content_written"
+msgstr "content_written"
+
+#: ../../plugins.rst:178 001ad90e09ab4b21a702b2ed9771a156
+msgid "path, context"
+msgstr "path, context"
+
+#: ../../plugins.rst:178 69b05b02e1564fe4b48dbd2926fdaec3
+msgid "invoked each time a content file is written."
+msgstr "每一次内容文件写入后调用。"
+
+#: ../../plugins.rst:179 30938518f54f46028c8fd03808471be7
+msgid "feed_generated"
+msgstr "feed_generated"
+
+#: ../../plugins.rst:179 e29bf37e7114454099baa21955b7fce0
+msgid "context, feed"
+msgstr "context, feed"
+
+#: ../../plugins.rst:179 366ba164593242309dab922c36667dc3
+msgid ""
+"invoked each time a feed gets generated. Can be used to modify a feed "
+"object before it gets written."
+msgstr "每个feed生成前调用。可以用于在feed写入前修改之。"
+
+#: ../../plugins.rst:181 0b6d7fc85d374b9c82c60d4a0df69fcd
+msgid "feed_written"
+msgstr "feed_written"
+
+#: ../../plugins.rst:181 d3fdc3a669e9418b9f6e738c549fa151
+msgid "path, context, feed"
+msgstr "path, context, feed"
+
+#: ../../plugins.rst:181 3da952e464034f8c8491caa94f0aec2d
+msgid "invoked each time a feed file is written."
+msgstr "每一个feed文件写入后调用。"
+
+#: ../../plugins.rst:186 24bf768827184a8a9c2ad9d23d3549e4
+msgid ""
+"Avoid ``content_object_init`` signal if you intend to read ``summary`` or"
+" ``content`` properties of the content object. That combination can "
+"result in unresolved links when :ref:`ref-linking-to-internal-content` "
+"(see `pelican-plugins bug #314`_). Use ``_summary`` and ``_content`` "
+"properties instead, or, alternatively, run your plugin at a later stage "
+"(e.g. ``all_generators_finalized``)."
+msgstr ""
+"请避免使用 ``content_object_init`` 信号读取content对象的 ``summary`` 或 "
+"``content`` 属性,这可能导致在 :ref:`ref-linking-to-internal-content` 时无法"
+"解析链接(请参阅 `pelican-plugins bug #314`_ )。请改用 ``_summary`` 和 "
+"``_content`` 属性,或者就在后续阶段再运行插件(例如 ``all_generators_finalized`` 时)。"
+
+#: ../../plugins.rst:195 9222300d10c74a9eb27fc229488e63a4
+msgid ""
+"After Pelican 3.2, signal names were standardized. Older plugins may "
+"need to be updated to use the new names:"
+msgstr ""
+"Pelican3.2之后,信号名都进行了标准化,较老的插件可能需要进行更新:"
+
+#: ../../plugins.rst:199 2ba779a696064672965e17c70f70d927
+msgid "Old name"
+msgstr "旧名称"
+
+#: ../../plugins.rst:199 d21e933be9064983aa2cfaeca4f00cb9
+msgid "New name"
+msgstr "新名称"
+
+#: ../../plugins.rst:201 805ac7c62fc94113a3481890793f5417
+msgid "article_generate_context"
+msgstr "article_generate_context"
+
+#: ../../plugins.rst:202 d6f1a03ae49349b091045c8079b80d44
+msgid "article_generate_finalized"
+msgstr "article_generate_finalized"
+
+#: ../../plugins.rst:203 c967c8322a744c2c970beb6b98b90743
+msgid "article_generate_preread"
+msgstr "article_generate_preread"
+
+#: ../../plugins.rst:204 71adeb83fba74317ad0fac5784612a3d
+msgid "pages_generate_context"
+msgstr "pages_generate_context"
+
+#: ../../plugins.rst:205 d2297a5ec351411e8a66a74d8168caa0
+msgid "pages_generate_preread"
+msgstr "pages_generate_preread"
+
+#: ../../plugins.rst:206 fb572935b7f445d298ff2c9c89c59c4e
+msgid "pages_generator_finalized"
+msgstr "pages_generator_finalized"
+
+#: ../../plugins.rst:207 0bb615d8a6f643a3a1a9abac2ec4f712
+msgid "pages_generator_init"
+msgstr "pages_generator_init"
+
+#: ../../plugins.rst:208 beddb5f81a62458b87c0703355a7b5a4
+msgid "static_generate_context"
+msgstr "static_generate_context"
+
+#: ../../plugins.rst:209 8fe8895dcb464e11bb01657e975f1352
+msgid "static_generate_preread"
+msgstr "static_generate_preread"
+
+#: ../../plugins.rst:213 44b14caddfd245c18cacd755fd0023e9
+msgid "Recipes"
+msgstr "具体使用方法举例"
+
+#: ../../plugins.rst:215 c24473f41cc84d028c99fa56af636037
+msgid ""
+"We eventually realised some of the recipes to create plugins would be "
+"best shared in the documentation somewhere, so here they are!"
+msgstr ""
+"下面分享了一些创建插件的具体方法,请享用!"
+
+#: ../../plugins.rst:219 96de26e8150e4339b3461d2dcc478cf3
+msgid "How to create a new reader"
+msgstr "如何创建一个新的reader"
+
+#: ../../plugins.rst:221 3f26c1183b814401b333bbd8528675d9
+msgid ""
+"One thing you might want is to add support for your very own input "
+"format. While it might make sense to add this feature in Pelican core, we"
+" wisely chose to avoid this situation and instead have the different "
+"readers defined via plugins."
+msgstr ""
+"你可能需要添加对输入文件格式的特殊支持。这似乎可以作为Pelican核心的一个功能,"
+"但我们选择避免将此功能放在核心中,而是通过插件实现不同的reader。"
+
+#: ../../plugins.rst:226 8167dcbaa6864da3b2262a2a99e08a15
+msgid ""
+"The rationale behind this choice is mainly that plugins are really easy "
+"to write and don't slow down Pelican itself when they're not active."
+msgstr ""
+"做出这个决定主要是因为实现这样的格式支持插件非常容易,而且这样在不需要此功能时"
+"也不会影响Pelican自身的速度。"
+
+#: ../../plugins.rst:229 26c8185062964b52921860cfa2ce508c
+msgid "No more talking — here is an example::"
+msgstr "多说无益,下面是一个具体例子:"
+
+#: ../../plugins.rst:265 ea51efb1925f45e79c87d6e5488cbbcd
+msgid "Adding a new generator"
+msgstr "添加新的generator"
+
+#: ../../plugins.rst:267 9e04f17a5fa1488d82d3629edf8cdf3f
+msgid ""
+"Adding a new generator is also really easy. You might want to have a look"
+" at :doc:`internals` for more information on how to create your own "
+"generator."
+msgstr ""
+"添加一个generator也非常简单,你可能会想要看一看 :doc:`internals` ,其中有关于"
+"如何创建generator的内容。"
+
+#: ../../plugins.rst:281 f4c92958e88a41a7a0deee697b48fc58
+msgid "Adding a new writer"
+msgstr "添加新的writer"
+
+#: ../../plugins.rst:283 188bf0e8a68446458ae525c67cfe098c
+msgid ""
+"Adding a writer will allow you to output additional file formats to disk,"
+" or change how the existing formats are written to disk. Note that only "
+"one writer will be active at a time, so be sure to either subclass the "
+"built-in Writer, or completely re-implement it."
+msgstr ""
+"添加writer可以让你将其他文件格式输出到磁盘,或者可以改变现有格式写入磁盘的方式。"
+"请注意,一次只能启用一个writer,因此请确保继承了内置的Writer,并且完全重新实现之。"
+
+#: ../../plugins.rst:288 edb5d1fa15bc48859c2912ba7c344286
+msgid "Here is a basic example of how to set up your own writer::"
+msgstr "下面是启用你的自定义writer的一个基本例子:"
+
+#: ../../plugins.rst:308 0df8f3318357472cbd72e17e1b5085b2
+msgid "Using Plugins to Inject Content"
+msgstr "使用插件添加内容"
+
+#: ../../plugins.rst:310 d0161dbe86c44111a6295259ec8cab54
+msgid ""
+"You can programmatically inject articles or pages using plugins. This can"
+" be useful if you plan to fetch articles from an API, for example."
+msgstr ""
+"可以通过插件以可编程的方式添加文章或页面。如果你打算从某些API获取文章,这就会很有用。"
+
+#: ../../plugins.rst:313 5d5c41dbeb7243d4b497752771bc7858
+msgid ""
+"Following is a simple example of how one can build a plugin that injects "
+"a custom article, using the ``article_generator_pretaxonomy`` signal::"
+msgstr ""
+"下面是一个简单的示例,说明了如何使用 ``article_generator_pretaxonomy`` "
+"信号构建一个添加自定义文章的插件:"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/publish.po b/docs/locale/zh_CN/LC_MESSAGES/publish.po
new file mode 100644
index 00000000..afb626f6
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/publish.po
@@ -0,0 +1,329 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-25 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../publish.rst:2 65617cfb871b492589d55186b708a1ce
+msgid "Publish your site"
+msgstr "发布站点"
+
+#: ../../publish.rst:7 dc4c9b1c1afd477d906b892dc592bdcd
+msgid "Site generation"
+msgstr "站点生成"
+
+#: ../../publish.rst:9 610c37360e2b49ec8ea630ddc224d2b7
+msgid ""
+"Once Pelican is installed and you have some content (e.g., in Markdown or"
+" reST format), you can convert your content into HTML via the ``pelican``"
+" command, specifying the path to your content and (optionally) the path "
+"to your :doc:`settings` file::"
+msgstr ""
+"您应该已经安装好Pelican并且已经创作了一些内容了吧(以Markdown或是reST格式),"
+"现在就可以将这些内容通过 ``pelican`` 命令转换为HTML了,在转换时需要指定"
+"创作内容存放的路径;如果有需要, :doc:`配置` 文件的路径也可单独指定:"
+
+#: ../../publish.rst:16 6f353c84f5204d2b84c49d1557010b19
+msgid ""
+"The above command will generate your site and save it in the ``output/`` "
+"folder, using the default theme to produce a simple site. The default "
+"theme consists of very simple HTML without styling and is provided so "
+"folks may use it as a basis for creating their own themes."
+msgstr ""
+"上面的指令会在 ``output/`` 目录下生成站点,使用的是默认的主题。默认主题只使用"
+"一些简单的HTML并且不包含样式,大家往往以这个简单主题为基础来创作自己的主题。"
+
+#: ../../publish.rst:21 bb5064d57ed144e6b85d7d3d0938f91c
+msgid ""
+"You can also tell Pelican to watch for your modifications, instead of "
+"manually re-running it every time you want to see your changes. To enable"
+" this, run the ``pelican`` command with the ``-r`` or ``--autoreload`` "
+"option. On non-Windows environments, this option can also be combined "
+"with the ``-l`` or ``--listen`` option to simultaneously both auto-"
+"regenerate *and* serve the output at http://localhost:8000::"
+msgstr ""
+"你也可以让Pelican来监听对源内容文件的修改,而不是在每次修改内容后重新手动执行命令"
+"来生成站点。在执行 ``pelican`` 命令时,加上 ``-r`` 或者 ``--autoreload`` 选项"
+"就可以做到这一点。在非Windows环境下,这个选项还可以和 ``-l`` 或 ``--listen`` "
+"搭配使用,这样就可以在自动重生成站点的基础上,同时提供在 http://localhost:8000 "
+"上的访问:"
+
+#: ../../publish.rst:30 40089a6762204e27bd16afaa038a8277
+msgid ""
+"Pelican has other command-line switches available. Have a look at the "
+"help to see all the options you can use::"
+msgstr ""
+"Pelican还有一些其他的命令行选项。可以在帮助中看到所有可用选项:"
+
+#: ../../publish.rst:36 4484bb6f6e2b4bd49027c98be4fa2cd8
+msgid "Viewing the generated files"
+msgstr "浏览生成的文件"
+
+#: ../../publish.rst:38 4dc83b844c964bcab17af21fabd5e6b2
+msgid ""
+"The files generated by Pelican are static files, so you don't actually "
+"need anything special to view them. You can use your browser to open the "
+"generated HTML files directly::"
+msgstr ""
+"Pelican生成的文件都是静态的,也就是说不需要使用什么特殊的手段就可以浏览。"
+"您可以直接使用浏览器打开生成的HTML文件:"
+
+#: ../../publish.rst:44 c5774634f7da4f64bb7c7d0adbcdb65b
+msgid ""
+"Because the above method may have trouble locating your CSS and other "
+"linked assets, running Pelican's simple built-in web server will often "
+"provide a more reliable previewing experience::"
+msgstr ""
+"事实上,上面所说的直接打开的方式可能会使CSS或其他链接上出现问题,"
+"可以运行Pelican自带的简易web服务器,如此便可以获得可靠的预览体验:"
+
+#: ../../publish.rst:50 b2eab6914b854b40bd769433fbad21b7
+msgid ""
+"Once the web server has been started, you can preview your site at: "
+"http://localhost:8000/"
+msgstr ""
+"当web服务器启动后,可以访问 http://localhost:8000/ 来预览您的站点。"
+
+#: ../../publish.rst:54 3b7344cad46a4dfaa01c067dd1f4009b
+msgid "Deployment"
+msgstr "部署"
+
+#: ../../publish.rst:56 de2815c211b84291a985a1d808ffbfe7
+msgid ""
+"After you have generated your site, previewed it in your local "
+"development environment, and are ready to deploy it to production, you "
+"might first re-generate your site with any production-specific settings "
+"(e.g., analytics, feeds, etc.) that you may have defined::"
+msgstr ""
+"当您生成好站点后,可以在本地先进行预览,确认无误后,在部署前可能还需使用"
+"生产环境特定的配置文件重新生成站点:"
+
+#: ../../publish.rst:63 56e568114b72443ebcf1f741f07504dc
+msgid ""
+"To base your publish configuration on top of your ``pelicanconf.py``, you"
+" can import your ``pelicanconf`` settings by including the following line"
+" in your ``publishconf.py``::"
+msgstr ""
+"您可以基于 ``pelicanconf.py`` 进行设置文件的配置, 在 ``publishconf.py`` "
+"中import ``pelicanconf`` 就可实现(译者注:配置文件其实本质上就是一些"
+"Python变量,因此import后就可以全部引入):"
+
+#: ../../publish.rst:69 b9e1243ed9ba409890d86ef8ff85499d
+msgid ""
+"If you have generated a ``publishconf.py`` using ``pelican-quickstart``, "
+"this line is included by default."
+msgstr ""
+"如果 ``publishconf.py`` 是通过 ``pelican-quickstart`` 生成的,上面这行默认就有。"
+
+#: ../../publish.rst:72 39671d42b0bb4c828fc51c63c351402c
+msgid ""
+"The steps for deploying your site will depend on where it will be hosted."
+" If you have SSH access to a server running Nginx or Apache, you might "
+"use the ``rsync`` tool to transmit your site files::"
+msgstr ""
+"部署站点的方法步骤取决于网站托管的位置。对于使用SSH访问的运行着Nginx或"
+"Apache的服务器,您可能需要使用 ``rsync`` 工具来传输站点文件:"
+
+#: ../../publish.rst:78 523ed256e0164a968d8580310e4a9304
+msgid ""
+"There are many other deployment options, some of which can be configured "
+"when first setting up your site via the ``pelican-quickstart`` command. "
+"See the :doc:`Tips` page for detail on publishing via GitHub Pages."
+msgstr ""
+"还有很多其他的部署方式供您选择,有一些在第一次通过 ``pelican-quickstart`` "
+"命令建立站点时就已经配置。在 :doc:`小技巧` 中可以查看如何通过"
+"Github Pages部署站点。"
+
+#: ../../publish.rst:83 c44ecc79922d419b8627706a6694dd8c
+msgid "Automation"
+msgstr "自动化"
+
+#: ../../publish.rst:85 b892dcba14a84306aa6b39295b5f81e3
+msgid ""
+"While the ``pelican`` command is the canonical way to generate your site,"
+" automation tools can be used to streamline the generation and "
+"publication flow. One of the questions asked during the ``pelican-"
+"quickstart`` process pertains to whether you want to automate site "
+"generation and publication. If you answered \"yes\" to that question, a "
+"``tasks.py`` and ``Makefile`` will be generated in the root of your "
+"project. These files, pre-populated with certain information gleaned from"
+" other answers provided during the ``pelican-quickstart`` process, are "
+"meant as a starting point and should be customized to fit your particular"
+" needs and usage patterns. If you find one or both of these automation "
+"tools to be of limited utility, these files can be deleted at any time "
+"and will not affect usage of the canonical ``pelican`` command."
+msgstr ""
+"``pelican`` 命令是生成站点的标准方法,但同时也有自动化工具可以用来简化生成与"
+"发布流程。在 ``pelican-quickstart`` 的过程中,其中一个问题就是是否启用自动站点"
+"生成与发布。若您选择了 “yes”,在项目的根目录中就会生成 ``tasks.py`` "
+"和 ``Makefile`` 。这些文件中预填充了一些从 ``pelican-quickstart`` 过程中"
+"收集的信息,您应该从这个生成好的文件出发,再根据实际需要进一步修改。"
+"另外,如果您认为这些自动化脚本文件没什么用,完全可以将他们删除,这不会对标准命令 "
+"``pelican`` 产生任何影响。"
+
+#: ../../publish.rst:98 4c49ca3a24e3462a984dda738875ed4e
+msgid ""
+"Following are automation tools that \"wrap\" the ``pelican`` command and "
+"can simplify the process of generating, previewing, and uploading your "
+"site."
+msgstr ""
+"下面是一些自动化工具,其中包装了 ``pelican`` 命令,可以用于简化生成、预览和"
+"上传站点的过程。"
+
+#: ../../publish.rst:102 103fb7405038442aae62b62ea0fcdbe5
+msgid "Invoke"
+msgstr "Invoke"
+
+#: ../../publish.rst:104 d3e46bf8da96489e923f6497e8932538
+msgid ""
+"The advantage of Invoke_ is that it is written in Python and thus can be "
+"used in a wide range of environments. The downside is that it must be "
+"installed separately. Use the following command to install Invoke, "
+"prefixing with ``sudo`` if your environment requires it::"
+msgstr ""
+"Invoke_ 工具使用Python作为编程语言,并且能够用在很多不同的环境中。它需要使用"
+"下面的命令单独安装,在某些操作系统中可能需要在前面加上 ``sudo`` :"
+
+#: ../../publish.rst:111 786359d08e8f45598df7b1c45e32ca0a
+msgid ""
+"Take a moment to open the ``tasks.py`` file that was generated in your "
+"project root. You will see a number of commands, any one of which can be "
+"renamed, removed, and/or customized to your liking. Using the out-of-the-"
+"box configuration, you can generate your site via::"
+msgstr ""
+"可以打开 ``tasks.py`` 文件看看其中的代码,可以尝试更改和删除其中的命令,"
+"也可以按照您的喜好自行进行其他修改。生成好的文件是开箱即用的,您可以通过"
+"下面的命令生成站点:"
+
+#: ../../publish.rst:118 ../../publish.rst:166 04c6045b58c24bc1a1fd594cdcf4ef5c
+#: 1e9cf29276ec4446b1b0f4a55a1ef4b8
+msgid ""
+"If you'd prefer to have Pelican automatically regenerate your site every "
+"time a change is detected (which is handy when testing locally), use the "
+"following command instead::"
+msgstr ""
+"若您希望Pelican在检测到变化时自动重新生成站点(在本地测试的时候很实用),"
+"可以使用下面的命令:"
+
+#: ../../publish.rst:124 ../../publish.rst:172 fabe0ce08eca4c5ebd9ca65898dab138
+#: ff42351e29b944a59e8df22b1cbb20f5
+msgid ""
+"To serve the generated site so it can be previewed in your browser at "
+"http://localhost:8000/::"
+msgstr ""
+"下面的命令则可以让您在生成后通过浏览器访问 http://localhost:8000/ 来预览站点"
+
+#: ../../publish.rst:129 e1b12a6c64b246f89aea105b8d7febbc
+msgid ""
+"To serve the generated site with automatic browser reloading every time a"
+" change is detected, first ``python -m pip install livereload``, then use"
+" the following command::"
+msgstr ""
+"在每次检测到修改重生成站点后,可以让浏览器自动进行重载。先运行 "
+"``python -m pip install livereload`` 安装,再运行下面的这条命令就可以实现:"
+
+#: ../../publish.rst:135 bf0d6c7770fe4a399b81b9ebdd48fa4e
+msgid ""
+"If during the ``pelican-quickstart`` process you answered \"yes\" when "
+"asked whether you want to upload your site via SSH, you can use the "
+"following command to publish your site via rsync over SSH::"
+msgstr ""
+"如果在 ``pelican-quickstart`` 过程中,对是否要通过SSH上传站点问题回答了“yes”,"
+"您就可以使用下面的命令借助rsync在SSH上发布站点:"
+
+#: ../../publish.rst:141 9bea9f82ce164ee5ba07349a4c4d58ea
+msgid ""
+"These are just a few of the commands available by default, so feel free "
+"to explore ``tasks.py`` and see what other commands are available. More "
+"importantly, don't hesitate to customize ``tasks.py`` to suit your "
+"specific needs and preferences."
+msgstr ""
+"默认就可以使用的命令远不止这些,在 ``tasks.py`` 中可以找到更多可用的命令。"
+"更重要的是,当您有特定需求和偏好时,直接修改 ``tasks.py`` 即可。"
+
+#: ../../publish.rst:147 06a6e7232c6243d79ab9f43ddc28590d
+msgid "Make"
+msgstr "Make"
+
+#: ../../publish.rst:149 a2a5b589cf804fcd83ee2d0fbf98c12d
+msgid ""
+"A ``Makefile`` is also automatically created for you when you say \"yes\""
+" to the relevant question during the ``pelican-quickstart`` process. The "
+"advantage of this method is that the ``make`` command is built into most "
+"POSIX systems and thus doesn't require installing anything else in order "
+"to use it. The downside is that non-POSIX systems (e.g., Windows) do not "
+"include ``make``, and installing it on those systems can be a non-trivial"
+" task."
+msgstr ""
+"``Makefile`` 也是自动生成的。在大多数POSIX系统中都内置了 ``make`` 命令,"
+"无需安装即可使用。但在非POSIX系统(例如Windows)中并没有 ``make`` ,在这些"
+"系统中安装 ``make`` 则往往比较麻烦。"
+
+#: ../../publish.rst:156 68c38c3eb34e4e6ca9cd4a2d3646d5cb
+msgid ""
+"If you want to use ``make`` to generate your site using the settings in "
+"``pelicanconf.py``, run::"
+msgstr ""
+"使用 ``make`` 命令是以 ``pelicanconf.py`` 作为配置文件来生成站点的:"
+
+#: ../../publish.rst:161 133e6e1ebf92412a85eedbe56e0b91af
+msgid ""
+"To generate the site for production, using the settings in "
+"``publishconf.py``, run::"
+msgstr ""
+"使用 ``publishconf.py`` 作为配置文件来为生产环境生成站点:"
+
+#: ../../publish.rst:177 f4e250949c2145ceb03b65c875767abc
+msgid ""
+"Normally you would need to run ``make regenerate`` and ``make serve`` in "
+"two separate terminal sessions, but you can run both at once via::"
+msgstr ""
+"一般来说, ``make regenerate`` 和 ``make serve`` 需要在分别在单独的终端会话中"
+"运行,下面的命令相当于同时运行上述两个命令:"
+
+#: ../../publish.rst:182 1f83bbcf60134eef959370bb5ca402d9
+msgid ""
+"The above command will simultaneously run Pelican in regeneration mode as"
+" well as serve the output at http://localhost:8000."
+msgstr ""
+"上面的命令会让Pelican在重生成模式下持续运行,同样地,您可以通过 "
+"http://localhost:8000 访问生成的站点。"
+
+#: ../../publish.rst:185 9274a68b1e3b4639bf638a044eda613d
+msgid ""
+"When you're ready to publish your site, you can upload it via the "
+"method(s) you chose during the ``pelican-quickstart`` questionnaire. For "
+"this example, we'll use rsync over ssh::"
+msgstr ""
+"当准备好发布站点时,可以使用在 ``pelican-quickstart`` 过程中选择的方法进行上传。"
+"下面的例子使用rsync在ssh上完成这一工作:"
+
+#: ../../publish.rst:191 9d7e7927c183491f981aacebe14e5bf1
+msgid "That's it! Your site should now be live."
+msgstr "OK!您的站点现在已经可以访问了。"
+
+#: ../../publish.rst:193 8f570acd5f494f5b9645fdbca6db6fbb
+msgid ""
+"(The default ``Makefile`` and ``devserver.sh`` scripts use the ``python``"
+" and ``pelican`` executables to complete its tasks. If you want to use "
+"different executables, such as ``python3``, you can set the ``PY`` and "
+"``PELICAN`` environment variables, respectively, to override the default "
+"executable names.)"
+msgstr ""
+"(默认的 ``Makefile`` 和 ``devserver.sh`` 脚本执行 ``python`` 和 ``pelican`` "
+"来完成任务。若您希望使用其他的可执行文件,例如 ``python3`` ,设置环境变量 ``PY`` "
+"和 ``PELICAN`` 来覆盖默认的可执行文件名)"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/quickstart.po b/docs/locale/zh_CN/LC_MESSAGES/quickstart.po
new file mode 100644
index 00000000..42ad4387
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/quickstart.po
@@ -0,0 +1,151 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-25 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../quickstart.rst:2 e5f32d61440744aab3f878488ef9e1e3
+msgid "Quickstart"
+msgstr "快速开始"
+
+#: ../../quickstart.rst:4 d3762ec7c3934f85b25b04cf4024a90c
+msgid ""
+"Reading through all the documentation is highly recommended, but for the "
+"truly impatient, following are some quick steps to get started."
+msgstr ""
+"强烈建议将所有文档完整地看一遍,但如果您目前没空,下面的步骤可以帮助您快速开始"
+"使用Pelican。"
+
+#: ../../quickstart.rst:8 c5982d5ecf7c445590254370b84995be
+msgid "Installation"
+msgstr "安装"
+
+#: ../../quickstart.rst:10 fda7d08c05f14e2fa0c07a4a1d216db5
+msgid ""
+"Install Pelican (and optionally Markdown if you intend to use it) on "
+"Python |min_python| by running the following command in your preferred "
+"terminal, prefixing with ``sudo`` if permissions warrant::"
+msgstr ""
+"在命令行中执行下面的命令以安装Pelican(如果您需要Markdown支持的话,也可以同时安装之)。"
+"Pelican需要使用 |min_python| 以上版本的Python。在必要情况下,请在命令前加上 ``sudo`` 。"
+
+#: ../../quickstart.rst:17 9db650d9dc9d4ac48df4dd9fc0a246ac
+msgid "Create a project"
+msgstr "创建项目"
+
+#: ../../quickstart.rst:19 2e9a72a878754604abdb27d9ec37937e
+msgid ""
+"First, choose a name for your project, create an appropriately-named "
+"directory for your site, and switch to that directory::"
+msgstr ""
+"首先,给您的项目想个名字,并以合适的名字创建一个文件夹来存放您的站点。"
+"接着,进入这个新创建的文件夹:"
+
+#: ../../quickstart.rst:25 da759420dd8440b485936a5a054f142a
+msgid ""
+"Create a skeleton project via the ``pelican-quickstart`` command, which "
+"begins by asking some questions about your site::"
+msgstr ""
+"通过 ``pelican-quickstart`` 命令创建一个项目的框架,执行这个命令后,"
+"您需要输入一些站点相关的信息:"
+
+#: ../../quickstart.rst:30 eb2d702c9f5a4981a93f805e98674cfe
+msgid ""
+"For questions that have default values denoted in brackets, feel free to "
+"use the Return key to accept those default values [#tzlocal_fn]_. When "
+"asked for your URL prefix, enter your domain name as indicated (e.g., "
+"``https://example.com``)."
+msgstr ""
+"对于那些在括号中写了默认值的问题,完全可以直接回车以使用预设值 [#tzlocal_fn]_。"
+"在输入站点URL的前缀(prefix)时,请根据提示的格式输入站点的域名(例如 "
+"``https://example.com``)。"
+
+#: ../../quickstart.rst:36 66d29d63cce0488a8ec9e43ce97035f9
+msgid "Create an article"
+msgstr "创作文章"
+
+#: ../../quickstart.rst:38 03af35552ef84e4491b46d8bf8c0f51e
+msgid ""
+"You cannot run Pelican until you have created some content. Use your "
+"preferred text editor to create your first article with the following "
+"content::"
+msgstr ""
+"您可以使用喜欢的文本编辑器来创建第一篇文章。下面是一个样例,可以将它作为您的第一篇文章:"
+
+#: ../../quickstart.rst:47 165d46a3f9da4f949375c70115fdeb3b
+msgid ""
+"Given that this example article is in Markdown format, save it as "
+"``~/projects/yoursite/content/keyboard-review.md``."
+msgstr ""
+"上面这篇文章是以Markdown的格式完成的,一定要将其保存在站点目录的content文件夹下,例如 "
+"``~/projects/yoursite/content/keyboard-review.md``。"
+
+#: ../../quickstart.rst:51 5cc306848439434f81708eddee812f0e
+msgid "Generate your site"
+msgstr "生成站点"
+
+#: ../../quickstart.rst:53 03037d0c3b0b4a64b957f8284f008c9d
+msgid ""
+"From your project root directory, run the ``pelican`` command to generate"
+" your site::"
+msgstr ""
+"在项目的根目录下,直接运行命令 ``pelican`` 就可以生成您自己的站点了:"
+
+#: ../../quickstart.rst:57 abadae17b6f94e36b8603bad69f6e24f
+msgid ""
+"Your site has now been generated inside the ``output/`` directory. (You "
+"may see a warning related to feeds, but that is normal when developing "
+"locally and can be ignored for now.)"
+msgstr ""
+"站点会生成在 ``output/`` 目录下。(此时可能会显示和feeds有关的警告,这和当前的"
+"本地开发环境有关,目前可以忽略之)"
+
+#: ../../quickstart.rst:62 7cf36e609f544f02a0c800f8412cf79c
+msgid "Preview your site"
+msgstr "预览站点"
+
+#: ../../quickstart.rst:64 1a64015c5cc9401bac0a6ac953164fb3
+msgid ""
+"Open a new terminal session, navigate to your project root directory, and"
+" run the following command to launch Pelican's web server::"
+msgstr ""
+"打开一个新的命令行,进入刚才项目的根目录,执行下面的命令以运行一个Pelican web服务器:"
+
+#: ../../quickstart.rst:69 eb286b4785304d22a46e90884d26de07
+msgid "Preview your site by navigating to http://localhost:8000/ in your browser."
+msgstr "打开浏览器,进入 http://localhost:8000/ 就可以看到刚刚生成的站点了。"
+
+#: ../../quickstart.rst:71 1dc30b5cb267402c9da251303ff59dbf
+msgid ""
+"Continue reading the other documentation sections for more detail, and "
+"check out the Pelican wiki's Tutorials_ page for links to community-"
+"published tutorials."
+msgstr ""
+"请继续阅读文档中的其他部分来了解Pelican的更多用法,也可以前往Pelican的"
+"wiki 教程_ 页面获取社区发布的教程。"
+
+#: ../../quickstart.rst:78 6c135ea1cbb44400b446c0f9074e0fc5
+msgid "Footnotes"
+msgstr "脚注"
+
+#: ../../quickstart.rst:80 911df4217fd94e6184502153ed0e53dc
+msgid ""
+"You can help localize default fields by installing the optional `tzlocal "
+"`_ module."
+msgstr ""
+"您可以安装可选模块 `tzlocal `_ 来"
+"本地化默认字段。"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/report.po b/docs/locale/zh_CN/LC_MESSAGES/report.po
new file mode 100644
index 00000000..6cbab7f7
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/report.po
@@ -0,0 +1,249 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../report.rst:2 bc25575efa494c7b9455e02eb5c514ab
+msgid "Some history about Pelican"
+msgstr "Pelican的一些历史"
+
+#: ../../report.rst:6 959bbe068d2e4fd19e48be22706070d2
+msgid ""
+"This page comes from a report the original author (Alexis Métaireau) "
+"wrote right after writing Pelican, in December 2010. The information may "
+"not be up-to-date."
+msgstr ""
+"此页面来自原作者 Alexis Métaireau 在2010年12月完成Pelican后作的一篇报告,因此"
+"其中涉及的具体内容可能和最新的Pelican有些出入。"
+
+#: ../../report.rst:10 598beb4776eb4a7bb1c928979752b1f1
+msgid ""
+"Pelican is a simple static blog generator. It parses markup files "
+"(Markdown or reStructuredText for now) and generates an HTML folder with "
+"all the files in it. I've chosen to use Python to implement Pelican "
+"because it seemed to be simple and to fit to my needs. I did not wanted "
+"to define a class for each thing, but still wanted to keep my things "
+"loosely coupled. It turns out that it was exactly what I wanted. From "
+"time to time, thanks to the feedback of some users, it took me a very few"
+" time to provide fixes on it. So far, I've re-factored the Pelican code "
+"by two times; each time took less than 30 minutes."
+msgstr ""
+"Pelican是一个简单的静态博客生成器。它解析标记文件(目前主要是Markdown和"
+"reStructuredText),并生成一个文件夹,其中包含了对应于标记文件的HTML。由于Python"
+"很简单并且符合需求,我选择使用Python来实现Pelican。我不想为每个东西定义一个类,"
+"但同时又想要各部件之间低耦合。事实证明,这正是我想要的。在发展过程中,多亏了用户"
+"给的反馈,我花了些时间修复了一些问题。到目前为止,我已经将Pelican的代码重构了两次,"
+"每次重构都不会超过30分钟。"
+
+#: ../../report.rst:21 1709ab99c3144cb692afd1d1bc388921
+msgid "Use case"
+msgstr "使用场景"
+
+#: ../../report.rst:23 119f315a8e6c409d98783a636ac2147c
+msgid ""
+"I was previously using WordPress, a solution you can host on a web server"
+" to manage your blog. Most of the time, I prefer using markup languages "
+"such as Markdown or reStructuredText to type my articles. To do so, I use"
+" vim. I think it is important to let the people choose the tool they want"
+" to write the articles. In my opinion, a blog manager should just allow "
+"you to take any kind of input and transform it to a weblog. That's what "
+"Pelican does. You can write your articles using the tool you want, and "
+"the markup language you want, and then generate a static HTML weblog."
+msgstr ""
+"我之前使用的是WordPress,你可以将它部署在Web服务器上来管理博客。大多数时候,"
+"我更喜欢使用Markdown或reStructuredText等标记语言来撰写文章。为此,我一般用vim"
+"来写这些文章。我认为让大家自行选择用于写文章的工具是很重要的。在我看来,博客管理器"
+"应该能够接受任何类型的输入并将其转换为博客站。Pelican就采取这一思想。您可以选择自己"
+"喜欢的工具以及标记语言来撰写文章,然后生成静态的HTML博客站。"
+
+#: ../../report.rst:34 1a087a07690c4c35873a7f4ce18ba52b
+msgid ""
+"To be flexible enough, Pelican has template support, so you can easily "
+"write your own themes if you want to."
+msgstr ""
+"为了足够的灵活性,Pelican中支持使用模板,这样你就可以编写自己的主题了。"
+
+#: ../../report.rst:38 fca5a0962a0d4c27aa163f2aec94b1cf
+msgid "Design process"
+msgstr "设计过程"
+
+#: ../../report.rst:40 073dd0b024fa4701acc0078b84c45648
+msgid ""
+"Pelican came from a need I have. I started by creating a single file "
+"application, and I have make it grow to support what it does by now. To "
+"start, I wrote a piece of documentation about what I wanted to do. Then, "
+"I created the content I wanted to parse (the reStructuredText files) and "
+"started experimenting with the code. Pelican was 200 lines long and "
+"contained almost ten functions and one class when it was first usable."
+msgstr ""
+"Pelican来源于我的需求。从单文件应用程序出发,不断成长为现在功能丰富的应用。首先,我"
+"写了一份需求文档;然后创建了我想要解析的内容(reStructuredText文件),并开始"
+"实验性的编写代码。Pelican的第一个能够使用的版本包含了200行代码、10个函数以及1个类。"
+
+#: ../../report.rst:47 f407fc9ad9434f1082014eeca8c4cc89
+msgid ""
+"I have been facing different problems all over the time and wanted to add"
+" features to Pelican while using it. The first change I have done was to "
+"add the support of a settings file. It is possible to pass the options to"
+" the command line, but can be tedious if there is a lot of them. In the "
+"same way, I have added the support of different things over time: Atom "
+"feeds, multiple themes, multiple markup support, etc. At some point, it "
+"appears that the \"only one file\" mantra was not good enough for "
+"Pelican, so I decided to rework a bit all that, and split this in "
+"multiple different files."
+msgstr ""
+"我不断遇到各种问题,在使用过程中还想要往Pelican中添加功能。在对代码的第一次修改中,"
+"添加了对配置文件的支持。虽然可以在命令行中往里传入选项,但当配置项多起来后,就会变得"
+"异常冗长。同样地,Pelican支持了越来越多的功能:Atom订阅源、多主体支持、多标记语言"
+"支持等等。在某一时刻,单文件应用已经不适合Pelican了,因此我决定多做些工作,将应用分离"
+"到多个文件中。"
+
+#: ../../report.rst:56 57b3d1ba492646e28e20396b78df8ea0
+msgid "I’ve separated the logic in different classes and concepts:"
+msgstr "我将系统整体逻辑分为如下几个类和概念:"
+
+#: ../../report.rst:58 2d4090dba6674569a7e1088919185aa5
+msgid ""
+"*writers* are responsible of all the writing process of the files. They "
+"are responsible of writing .html files, RSS feeds and so on. Since those "
+"operations are commonly used, the object is created once, and then passed"
+" to the generators."
+msgstr ""
+"**Writers** 负责文件的写入工作,即负责完成 html、RSS订阅源等文件的写入。因为这些"
+"操作都是比较常用的,这个类只会被创建一次,然后再传给Generators。"
+
+#: ../../report.rst:63 a4cff6dceb8f430791edaeb3b2280924
+msgid ""
+"*readers* are used to read from various formats (Markdown and "
+"reStructuredText for now, but the system is extensible). Given a file, "
+"they return metadata (author, tags, category, etc) and content (HTML "
+"formatted)."
+msgstr ""
+"**Readers** 用于读取不同格式的文件(目前支持Markdown、reStructuredText,"
+"但可以继续扩展)。向 **Readers** 输入一个文件,它会返回文档的元数据(作者、标签、"
+"分类等等)与HTML格式的文档正文内容。"
+
+#: ../../report.rst:67 6ed9719c06c2477ea05ea30e4806ad14
+msgid ""
+"*generators* generate the different outputs. For instance, Pelican comes "
+"with an ArticlesGenerator and PagesGenerator, into others. Given a "
+"configuration, they can do whatever you want them to do. Most of the time"
+" it's generating files from inputs (user inputs and files)."
+msgstr ""
+"**Generators** 用以生成不同的输出,Pelican自带了 ``ArticlesGenerator`` 和 "
+"``PageGenerator`` 。给定一套配置信息, **Generators** 可以做几乎任何事。"
+"但大多数情况下,它的工作就是从输入生成文件。"
+
+#: ../../report.rst:72 cb5129c105b04d788a908f580a83e7e1
+msgid ""
+"I also deal with contents objects. They can be ``Articles``, ``Pages``, "
+"``Quotes``, or whatever you want. They are defined in the ``contents.py``"
+" module and represent some content to be used by the program."
+msgstr ""
+"同样,还要处理正文对象。正文对象可以是 ``Articles`` 、 ``Pages`` 、 ``Quotes`` "
+"或者其他你想要的类型。这些对象在 ``contents.py`` 模块中完成定义,同时代表了应用中"
+"使用到的内容。"
+
+#: ../../report.rst:77 4123da2b628448359aa9ed20b2ca87d2
+msgid "In more detail"
+msgstr "更细节的内容"
+
+#: ../../report.rst:79 8482492940524edf8244fc220553cd3c
+msgid "Here is an overview of the classes involved in Pelican."
+msgstr "以下是Pelican中涉及的类的概述。"
+
+#: ../../report.rst:83 a8a39a1ccc154604b8bb000dff44982d
+msgid ""
+"The interface does not really exist, and I have added it only to clarify "
+"the whole picture. I do use duck typing and not interfaces."
+msgstr ""
+"上图中的接口事实上并不存在,我是为了整张图的完整性才加上去的。在实际实现中,使用了"
+"鸭子类型而不是接口。"
+
+#: ../../report.rst:86 889dfae0dc4242f0b21ce831c7172001
+msgid "Internally, the following process is followed:"
+msgstr "应用内部按以下流程进行处理:"
+
+#: ../../report.rst:88 fc5cbf8ca65c456c90c56c00cf5ab93f
+msgid ""
+"First of all, the command line is parsed, and some content from the user "
+"is used to initialize the different generator objects."
+msgstr ""
+"首先,解析命令行,并根据用户给入的一些内容来初始化不同的generator对象。"
+
+#: ../../report.rst:91 5d0c1dc643364248820fad76c204f663
+msgid ""
+"A ``context`` is created. It contains the settings from the command line "
+"and a settings file if provided."
+msgstr ""
+"创建一个 ``context`` ,其中包含了来自命令行和文件的配置信息。"
+
+#: ../../report.rst:93 36725875f2c14e0bb8fc60b16afa1367
+msgid ""
+"The ``generate_context`` method of each generator is called, updating the"
+" context."
+msgstr ""
+"调用各generator对象的 ``generate_context`` 方法来更新 ``context`` 。"
+
+#: ../../report.rst:95 d50a4b2e38884eb38f1b66fdf7fb1eda
+msgid ""
+"The writer is created and given to the ``generate_output`` method of each"
+" generator."
+msgstr ""
+"创建 **Writers** 并将其给入generator的 ``generate_output`` 方法。"
+
+#: ../../report.rst:98 da8d9096940044f2849112fb5efcb4cb
+msgid ""
+"I make two calls because it is important that when the output is "
+"generated by the generators, the context will not change. In other words,"
+" the first method ``generate_context`` should modify the context, whereas"
+" the second ``generate_output`` method should not."
+msgstr ""
+"由于当generator生成输出时并不会改变上下文,我进行了两次调用。换句话说,第一个方法 "
+"``generate_context`` 会修改上下文,而第二个方法 ``generate_output`` 不会。"
+
+#: ../../report.rst:103 a6350edba931463fb92ae51dd9bc253a
+msgid ""
+"Then, it is up to the generators to do what the want, in the "
+"``generate_context`` and ``generate_content`` method. Taking the "
+"``ArticlesGenerator`` class will help to understand some others concepts."
+" Here is what happens when calling the ``generate_context`` method:"
+msgstr ""
+"然后,事情就取决于各generator在 ``generate_context`` 和 ``generate_content`` "
+"中做的操作了。拿 ``ArticlesGenerator`` 举例可以帮助理解其他的一些概念。下面是调用 "
+"``generate_context`` 方法后会发生的事情:"
+
+#: ../../report.rst:108 4b99ddf2cf344d0b8fbd080c15adfb64
+msgid ""
+"Read the folder “path”, looking for restructured text files, load each of"
+" them, and construct a content object (``Article``) with it. To do so, "
+"use ``Reader`` objects."
+msgstr ""
+"读取文件夹路径,查找并加载每个restructured文件,并为每个文件构建一个正文内容对象( "
+"``Article`` )。此工作是由 ``Reader`` 对象完成的。"
+
+#: ../../report.rst:111 176a7a5896904f2e9929623ef652660b
+msgid "Update the ``context`` with all those articles."
+msgstr "根据所有的文章更新 ``context`` 。"
+
+#: ../../report.rst:113 bb88942c85004c4c9e0b55a72076b18f
+msgid ""
+"Then, the ``generate_content`` method uses the ``context`` and the "
+"``writer`` to generate the wanted output."
+msgstr ""
+"然后, ``generate_content`` 方法使用 ``context`` 和 ``writer`` 来生成想要的输出。"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/settings.po b/docs/locale/zh_CN/LC_MESSAGES/settings.po
new file mode 100644
index 00000000..36c7209e
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/settings.po
@@ -0,0 +1,1815 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-27 16:18+0800\n"
+"PO-Revision-Date: 2024-06-26 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../settings.rst:2 53029e75034c46d4b54eae3cd205fe2e
+msgid "Settings"
+msgstr "设置"
+
+#: ../../settings.rst:4 dd0b07017437474b99116d1c1927af95
+msgid ""
+"Pelican is configurable thanks to a settings file you can pass to the "
+"command line::"
+msgstr "可以通过命令行给Pelican传入配置文件:"
+
+#: ../../settings.rst:9 df860abc6301440b89366f2898aabd6f
+msgid ""
+"If you used the ``pelican-quickstart`` command, your primary settings "
+"file will be named ``pelicanconf.py`` by default."
+msgstr "如果使用的是 ``pelican-quickstart`` 命令,默认的主配置文件时 ``pelicanconf.py`` 。"
+
+#: ../../settings.rst:12 a7b47b4379934afcb2bfd9f5425c4a6c
+msgid ""
+"You can also specify settings via ``-e`` / ``--extra-settings`` option "
+"flags. It will override default settings as well as any defined within "
+"the setting file. Note that values must follow JSON notation::"
+msgstr ""
+"通过 ``-e`` / ``--extra-settings`` "
+"选项,可以直接指定一些配置来覆盖配置文件中的设置。需要注意的是,选项值必须时JSON格式的:"
+
+#: ../../settings.rst:18 16437361edd74b8fb84dcde3da35baa3
+msgid ""
+"Environment variables can also be used here but must be escaped "
+"appropriately::"
+msgstr "可以在命令中使用环境变量,但是需要正确地进行转义:"
+
+#: ../../settings.rst:24 71a1194ecd1b4a519877818ad172a44f
+msgid ""
+"When experimenting with different settings (especially the metadata ones)"
+" caching may interfere and the changes may not be visible. In such cases "
+"disable caching with ``LOAD_CONTENT_CACHE = False`` or use the "
+"``--ignore-cache`` command-line switch."
+msgstr ""
+"在尝试不同的设置(特别是尝试元数据)时,受缓存的干扰,对设置的更改可能不会生效。在这种情况下,指定 ``LOAD_CONTENT_CACHE = "
+"False`` 设置或 ``--ignore-cache`` 命令行选项即可。"
+
+#: ../../settings.rst:29 3362ac7659744fab9649c7d4edec7456
+msgid ""
+"Settings are configured in the form of a Python module (a file). There is"
+" an `example settings file "
+"`_"
+" available for reference."
+msgstr ""
+"设置以Python模块(一个文件)的形式。 `示例配置文件 "
+"`_"
+" 可供您参考。"
+
+#: ../../settings.rst:34 fd01256fff0d40319c6bd55c3e3d1f8d
+msgid ""
+"To see a list of current settings in your environment, including both "
+"default and any customized values, run the following command (append one "
+"or more specific setting names as arguments to see values for those "
+"settings only)::"
+msgstr "要查看当前环境下的配置,同时查看默认的或是自定义的配置值,执行下面的命令(在后面以参数的形式添加一个或多个指定的配置名称,可以单独查看指定的配置项):"
+
+#: ../../settings.rst:40 fd4f9ceda04c4b119adf0e6e3226842d
+msgid ""
+"All the setting identifiers must be set in all-caps, otherwise they will "
+"not be processed. Setting values that are numbers (5, 20, etc.), booleans"
+" (True, False, None, etc.), dictionaries, or tuples should *not* be "
+"enclosed in quotation marks. All other values (i.e., strings) *must* be "
+"enclosed in quotation marks."
+msgstr ""
+"所有设置的键(设置中的变量名)都必须是大写的,否则会被无视。配置值可能是数值(5、20等)、布尔值(True、False、None等)、字典或者元组。这些值应该以Python值的形式存在,"
+" *不* 需要用引号引起来。除此之外的其他配置值(例如字符串) *必须* 用引号引起来。"
+
+#: ../../settings.rst:46 aece462c39674aa68651567ca58ac940
+msgid ""
+"Unless otherwise specified, settings that refer to paths can be either "
+"absolute or relative to the configuration file. The settings you define "
+"in the configuration file will be passed to the templates, which allows "
+"you to use your settings to add site-wide content."
+msgstr "除非另有指定,设置中指定的路径可以是绝对路径,也可以是相对于配置文件的相对路径。设置中配置的东西会传递到网站模板中,这使得可以在配置文件中添加在整个站点中都能使用的内容。"
+
+#: ../../settings.rst:51 b3de78704bd34981bce53c625e7181ce
+msgid "Here is a list of settings for Pelican:"
+msgstr "下面是Pelican设置项的列表:"
+
+#: ../../settings.rst:55 4a3728c3d465496b903ad3bafef32da9
+msgid "Basic settings"
+msgstr "基础设置"
+
+#: ../../settings.rst:59 74ac50f3d3d847148d37db0c2f4dcb1a
+msgid ""
+"When you don't specify a category in your post metadata, set this setting"
+" to ``True``, and organize your articles in subfolders, the subfolder "
+"will become the category of your post. If set to ``False``, "
+"``DEFAULT_CATEGORY`` will be used as a fallback."
+msgstr ""
+"当您没有在推文中指定元数据categroy时,若本项设置设为了 ``True`` "
+",并且文章也是通过子文件夹进行分类管理的,那么这些子文件夹的名称就会作为发布内容的分类。若本项设为了 ``False`` ,会使用配置项 "
+"``DEFAULT_CATEGORY`` 作为默认分类。"
+
+#: ../../settings.rst:66 6fd89e4093cf42f7b7a15d12b806ae39
+msgid "The default category to fall back on."
+msgstr "默认的分类"
+
+#: ../../settings.rst:70 dce02cdf67434cc385bf4c1a0ab92931
+msgid ""
+"Whether to display pages on the menu of the template. Templates may or "
+"may not honor this setting."
+msgstr "指定是否将“页面”显示在模板的菜单中。模板可能不会遵循此项。"
+
+#: ../../settings.rst:75 830ab9b9933b488193d4b8afd85e6a31
+msgid ""
+"Whether to display categories on the menu of the template. Templates may "
+"or not honor this setting."
+msgstr "指定是否将“分类”显示在模板的菜单中。模板可能不会遵循此项。"
+
+#: ../../settings.rst:80 01ef16e7f3d7423b96ee3b57b0173ebc
+msgid ""
+"Extra configuration settings for the docutils publisher (applicable only "
+"to reStructuredText). See `Docutils Configuration`_ settings for more "
+"details."
+msgstr "docutils的额外配置项(只针对reStructuredText有效)。在 `Docutils 配置`_ 设置中查看更多信息。"
+
+#: ../../settings.rst:85 f7a9532b08ac43b4a61bd175ec91d66b
+msgid ""
+"Delete the output directory, and **all** of its contents, before "
+"generating new files. This can be useful in preventing older, unnecessary"
+" files from persisting in your output. However, **this is a destructive "
+"setting and should be handled with extreme care.**"
+msgstr ""
+"在生成新文件前删除输出目录和其中 **所有** 的内容。这可以避免一些老的无用的文件一直存在于输出目录中。但是, "
+"**此项配置是具有破坏性的,请谨慎使用** 。"
+
+#: ../../settings.rst:92 ff8c5e50c9ac40bb85e8384fcad6617e
+msgid ""
+"A list of filenames that should be retained and not deleted from the "
+"output directory. One use case would be the preservation of version "
+"control data."
+msgstr "一个文件名的列表,包含了应该保留,不从输出目录中删除的文件。可以用于版本控制数据的保留。"
+
+#: ../../settings.rst:95 ../../settings.rst:110 ../../settings.rst:136
+#: 7ee367e15d2549a5889dee6f67f9d5bf 8befd4f04dcf4f638e6a50972cf62f0e
+#: c5a4d3b37cd94412a6f37c8ad0dae8e1
+msgid "Example::"
+msgstr "例子:"
+
+#: ../../settings.rst:101 b188b54ab9bf46898663261c6b0bdbf9
+msgid ""
+"A dictionary of custom Jinja2 environment variables you want to use. This"
+" also includes a list of extensions you may want to include. See `Jinja "
+"Environment documentation`_."
+msgstr "一个字典,用于您想要用的自定义的Jinja2环境变量。这其中也包含了要使用的扩展列表。详见 `Jinja环境文档`_ "
+
+#: ../../settings.rst:107 57cdaaf600bf4c2aa461094e99584b54
+msgid ""
+"A dictionary of custom Jinja2 filters you want to use. The dictionary "
+"should map the filtername to the filter function."
+msgstr "一个字典,存放自定义的Jinja2过滤器。此字典中应该是过滤器名称到过滤器函数的映射。"
+
+#: ../../settings.rst:118 31c28dcad1a2433784678692606c7407
+msgid "See: `Jinja custom filters documentation`_."
+msgstr "详见: `Jinja自定义过滤器文档`_ 。"
+
+#: ../../settings.rst:122 33098b212ebb4c769d9a7e8e35e22f71
+msgid ""
+"A dictionary of custom objects to map into the Jinja2 global environment "
+"namespace. The dictionary should map the global name to the global "
+"variable/function. See: `Jinja global namespace documentation`_."
+msgstr ""
+"一个字典,可以将自定义对象映射到Jinja2的全局环境命名空间中。字典中应该是全局名称到全局变量/函数的映射。详见: "
+"`Jinja全局命名空间文档`_ 。"
+
+#: ../../settings.rst:128 9d07d4c867f644dbad534da8c17805eb
+msgid ""
+"A dictionary of custom Jinja2 tests you want to use. The dictionary "
+"should map test names to test functions. See: `Jinja custom tests "
+"documentation`_."
+msgstr "一个字典,自定义了要使用的Jinja测试。字典中应该是测试名到测试函数的映射。详见: `Jinja自定义测试文档`_ 。"
+
+#: ../../settings.rst:133 68fca89155b84571bf16ccc9e2d4d2f2
+msgid ""
+"A list of tuples containing the logging level (up to ``warning``) and the"
+" message to be ignored."
+msgstr "一个以元组为元素的列表,元组中包含日志等级(最高到 ``warning``)和要忽略的消息。"
+
+#: ../../settings.rst:142 2052888dbd6c4eb58148d383c23e6670
+msgid ""
+"A dictionary of file extensions / Reader classes for Pelican to process "
+"or ignore."
+msgstr "一个字典,记录了文件扩展名到Reader类的映射。可以据此让Pelican按照指定规则处理或忽略某些文件。"
+
+#: ../../settings.rst:145 5f70a62f7360438eb733791964a66c80
+msgid "For example, to avoid processing .html files, set::"
+msgstr "例如,下面的配置可以让Pelican忽略 .html的文件不处理:"
+
+#: ../../settings.rst:149 2d665ed99679489fb6a06fbd30754d6b
+msgid "To add a custom reader for the ``foo`` extension, set::"
+msgstr "为扩展名为 ``foo`` 的文件添加自定义的reader:"
+
+#: ../../settings.rst:155 726d7ea5aa2540139b82d68adf424a99
+msgid ""
+"A list of glob patterns. Files and directories matching any of these "
+"patterns will be ignored by the processor. For example, the default "
+"``['.#*']`` will ignore emacs lock files, and ``['__pycache__']`` would "
+"ignore Python 3's bytecode caches."
+msgstr ""
+"通配符模式的列表。任何匹配上的文件和目录都会被忽略。例如,默认的 ``['.#*']`` 可以忽略emacs的锁定文件, "
+"``['__pycache__']`` 则可以忽略Python3的字节码缓存文件。"
+
+#: ../../settings.rst:162 39fdbf56f4314015b8c61c7473b7046f
+msgid ""
+"Extra configuration settings for the Markdown processor. Refer to the "
+"Python Markdown documentation's `Options section `_ for a complete list of "
+"supported options. The ``extensions`` option will be automatically "
+"computed from the ``extension_configs`` option."
+msgstr ""
+"对Markdown处理器的额外配置。可以参考Python Markdown文档的 `选项章节 `_ ,查看可用选项的完整列表。其中的 "
+"``extensions_configs`` 选项会用于自动计算 ``extensions`` 选项。"
+
+#: ../../settings.rst:168 bcabc42f8a1143f28d39d928a84e5c80
+msgid "Defaults to::"
+msgstr "默认值为:"
+
+#: ../../settings.rst:180 dfb5d9dcf9034218a44c38fa5d94b6e4
+msgid ""
+"The dictionary defined in your settings file will replace this default "
+"one."
+msgstr "配置文件中的字典会覆盖默认设置。"
+
+#: ../../settings.rst:185 57124bf26ff24273a9fda76782a551e0
+msgid ""
+"Where to output the generated files. This should correspond to your web "
+"server's virtual host root directory."
+msgstr "输出生成文件的位置。此项配置应该和web服务器虚拟主机的根目录有关。"
+
+#: ../../settings.rst:190 61cce052ae5549f98e48a9da9548b1d4
+msgid ""
+"Path to content directory to be processed by Pelican. If undefined, and "
+"content path is not specified via an argument to the ``pelican`` command,"
+" Pelican will use the current working directory."
+msgstr "待Pelican处理的文件目录的路径。如果没有定义,也没有在 ``pelican`` 命令中通过参数指定,Pelican会默认使用当前工作目录。"
+
+#: ../../settings.rst:196 770d207912f24f7b989208ef921d761c
+msgid ""
+"A list of directories and files to look at for pages, relative to "
+"``PATH``."
+msgstr "此列表中的目录和文件会被视为页面,路径是相对于 ``PATH`` 的。"
+
+#: ../../settings.rst:200 6c39a2bdec444b59b7564f15c161483e
+msgid ""
+"A list of directories to exclude when looking for pages in addition to "
+"``ARTICLE_PATHS``."
+msgstr "除了 ``ARTICLE_PATHS`` 中的文件不会被视为页面外,此选项中也可指定不被视为页面的文件目录。"
+
+#: ../../settings.rst:205 ec472b45d27448538a216960335cede9
+msgid ""
+"A list of directories and files to look at for articles, relative to "
+"``PATH``."
+msgstr "此列表中的目录和文件会被视为文章,路径是相对于 ``PATH`` 的。"
+
+#: ../../settings.rst:210 7d45d3e60d0c4c0e8c75fafc6ee0bf1a
+msgid ""
+"A list of directories to exclude when looking for articles in addition to"
+" ``PAGE_PATHS``."
+msgstr "除了 ``PAGE_PATHS`` 中的文件不会被视为文章外,此选项中也可指定不被视为文章的文件目录。"
+
+#: ../../settings.rst:215 4b3fb145ed814ff49262ce0ad20f711a
+msgid ""
+"Set to True if you want to copy the articles and pages in their original "
+"format (e.g. Markdown or reStructuredText) to the specified "
+"``OUTPUT_PATH``."
+msgstr ""
+"如果你想要将文章和页面以源格式(例如Markdown或reStructuredText)复制一份到 ``OUTPUT_PATH`` "
+"目录中,就将此项设为True。"
+
+#: ../../settings.rst:220 4da18483b371405facd124c3e345594c
+msgid ""
+"Controls the extension that will be used by the SourcesGenerator. "
+"Defaults to ``.text``. If not a valid string the default value will be "
+"used."
+msgstr "控制会被SourcesGenerator使用的扩展名。默认为 ``.text`` 。如果设置的值是无效的,会使用默认值。"
+
+#: ../../settings.rst:225 86076613fd6d438ab908d53be5422f06
+msgid "The list of plugins to load. See :ref:`plugins`."
+msgstr "要加载的插件列表。详见 :ref:`插件` 。"
+
+#: ../../settings.rst:229 208cbbef07c742a3906f604c97a4d332
+msgid "A list of directories where to look for plugins. See :ref:`plugins`."
+msgstr "查找插件的目录列表。详见 :ref:`插件` 。"
+
+#: ../../settings.rst:233 265efbdef95744759fea79fd41a4003f
+msgid "Your site name"
+msgstr "站点名称"
+
+#: ../../settings.rst:237 d57d6f99c06b4776b31acc033c97f67b
+msgid ""
+"Base URL of your web site. Not defined by default, so it is best to "
+"specify your SITEURL; if you do not, feeds will not be generated with "
+"properly-formed URLs. If your site is available via HTTPS, this setting "
+"should begin with ``https://`` — otherwise use ``http://``. Then append "
+"your domain, with no trailing slash at the end. Example: ``SITEURL = "
+"'https://example.com'``"
+msgstr ""
+"网站的基URL。此选项没有默认值,因此最好是指定一下SITEURL;如果不指定,feeds就无法正确生成URL。如果站点使用了HTTPS,那么此项设定最好以"
+" ``https://`` 开头;否则使用 ``http://`` 即可。在协议后面接着就是域名,不要以斜杠结尾。一个例子: ``SITEURL "
+"= 'https://example.com'`` "
+
+#: ../../settings.rst:246 d4dd07a95a904806812b20ff3ec3049b
+msgid ""
+"A list of directories (relative to ``PATH``) in which to look for static "
+"files. Such files will be copied to the output directory without "
+"modification. Articles, pages, and other content source files will "
+"normally be skipped, so it is safe for a directory to appear both here "
+"and in ``PAGE_PATHS`` or ``ARTICLE_PATHS``. Pelican's default settings "
+"include the \"images\" directory here."
+msgstr ""
+"用于查找静态文件的目录列表。静态文件会原封不动地拷贝到输出目录中。文章、页面以及其他的内容源文件都会被跳过,因此一个目录可以安全地同时出现在此选项以及"
+" ``PAGE_PATHS`` 或 ``ARTICLE_PATHS`` 中。Pelican默认会将 \"images\" 目录包含在此选项中。"
+
+#: ../../settings.rst:255 fc85f34c9d9640f48e0c739cc2787847
+msgid "A list of directories to exclude when looking for static files."
+msgstr "此选项列表中的目录都会在搜索静态文件时排除在外。"
+
+#: ../../settings.rst:259 ff6eb957bf36419d8a6a376d3232c117
+msgid ""
+"If set to False, content source files will not be skipped when copying "
+"files found in ``STATIC_PATHS``. This setting is for backward "
+"compatibility with Pelican releases before version 3.5. It has no effect"
+" unless ``STATIC_PATHS`` contains a directory that is also in "
+"``ARTICLE_PATHS`` or ``PAGE_PATHS``. If you are trying to publish your "
+"site's source files, consider using the ``OUTPUT_SOURCES`` setting "
+"instead."
+msgstr ""
+"如果此选项设为False, ``STATIC_PATHS`` "
+"中的内容源文件将不会被忽略,也会像静态文件一样被原封不动地拷贝。此项设置是为了给3.5版本前的Pelican进行向后兼容的。若某个目录同时出现在了"
+" ``STATIC_PATHS`` 和 ``ARTICLE_PATHS`` 中,或 ``STATIC_PATHS`` 和 "
+"``PAGE_PATHS`` 中时才会生效。如果你是想将站点的源文件发布出去的话,请考虑使用 ``OUTPUT_SOURCES`` 设置。"
+
+#: ../../settings.rst:268 bf1a395929034faca5de2bf94514f5e3
+msgid ""
+"Create links instead of copying files. If the content and output "
+"directories are on the same device, then create hard links. Falls back "
+"to symbolic links if the output directory is on a different filesystem. "
+"If symlinks are created, don't forget to add the ``-L`` or ``--copy-"
+"links`` option to rsync when uploading your site."
+msgstr ""
+"为静态文件创建链接而不是复制文件本身。如果内容和输出目录位于同一设备上,则创建硬链接;如果输出目录位于不同的文件系统上,则回退至符号链接。若创建了符号链接,使用rsync上传网站时需要添加-L或"
+"--copy-links选项。"
+
+#: ../../settings.rst:276 c1931f5e9644460bb528a831fdd41a59
+msgid ""
+"If set to ``True``, and ``STATIC_CREATE_LINKS`` is ``False``, compare "
+"mtimes of content and output files, and only copy content files that are "
+"newer than existing output files."
+msgstr ""
+"当此项设为 ``True`` 且 ``STATIC_CREATE_LINKS`` 设为 ``False`` "
+"时才会生效,此时会比较mtime,只有在当前文件更新时才会执行拷贝。"
+
+#: ../../settings.rst:282 60d680a3b3f44bd6b4461c92057e4471
+msgid ""
+"If set to True, several typographical improvements will be incorporated "
+"into the generated HTML via the `Typogrify "
+"`_ library, which can be installed "
+"via: ``python -m pip install typogrify``"
+msgstr ""
+"若此项设置为True,一些显示上的改进将通过 `Typogrify `_"
+" 库合并到生成的HTML中。可以通过 ``python -m pip install typogrify`` 进行安装。"
+
+#: ../../settings.rst:289 db77faf7956845d1a2d4ff9150138017
+msgid ""
+"A list of tags for Typogrify to ignore. By default Typogrify will ignore "
+"``pre`` and ``code`` tags. This requires that Typogrify version 2.0.4 or "
+"later is installed"
+msgstr ""
+"指定Typogrify要忽略的标签列表。默认情况下,Typogrify将忽略 ``pre`` 和 ``code`` "
+"标签此项特性需要安装高于2.0.4版本的Typogrify。"
+
+#: ../../settings.rst:295 8fddf3800e844a189677f113252bee04
+msgid ""
+"This setting controls how Typogrify sets up the Smartypants filter to "
+"interpret multiple dash/hyphen/minus characters. A single ASCII dash "
+"character (``-``) is always rendered as a hyphen. The ``default`` setting"
+" does not handle en-dashes and converts double-hyphens into em-dashes. "
+"The ``oldschool`` setting renders both en-dashes and em-dashes when it "
+"sees two (``--``) and three (``---``) hyphen characters, respectively. "
+"The ``oldschool_inverted`` setting turns two hyphens into an em-dash and "
+"three hyphens into an en-dash."
+msgstr ""
+"此设置用于设置Typogrify的Smartypants过滤器,控制过滤器如何解析多个破折号/连字符/减号。单个ASCII破折号字符 "
+"(``-``) 始终被视为连字符。设为 ``default`` 时不处理短破折号,并会将双连字符转换为长破折号;设为 ``oldschool`` "
+"时会将两个 ( ``--`` ) 和三个 ( ``--`` ) 连字符分别呈现为短破折号和长破折号;设为 "
+"``oldschool_inverted`` 时则会将两个连字符转换为长破折号,而将三个连字符转换为短破折号。"
+
+#: ../../settings.rst:306 c110b209965c448c8e3ca4109edfa0d6
+msgid ""
+"When creating a short summary of an article, this will be the default "
+"length (measured in words) of the text created. This only applies if "
+"your content does not otherwise specify a summary. Setting to ``None`` "
+"will cause the summary to be a copy of the original content."
+msgstr ""
+"当未给文章或页面书写摘要时,会自动创建摘要,此设置指定了默认创建摘要的长度"
+"(以字/词为单位)。若将此项设为 ``None`` ,摘要会和原始内容一模一样。"
+
+#: ../../settings.rst:313 9d446d0be4d248e1b5ef7f5df1977310
+msgid ""
+"When creating a short summary of an article, this will be the number of "
+"paragraphs to use as the summary. This only applies if your content does "
+"not otherwise specify a summary. Setting to ``None`` will cause the "
+"summary to use the whole text (up to ``SUMMARY_MAX_LENGTH``) instead of "
+"just the first N paragraphs."
+msgstr ""
+"当未给文章或页面书写摘要时,会自动创建摘要。此设置指定了默认创建摘要的段落数,"
+"即将正文的前N段视为摘要。若将此项设为 ``None`` ,摘要会和原始内容一模一样,"
+"但具体还会遵循 ``SUMMARY_MAX_LENGTH`` 。"
+
+#: ../../settings.rst:321 6a04572678864a959a48dc83f4e78465
+msgid ""
+"When creating a short summary of an article and the result was truncated "
+"to match the required word length, this will be used as the truncation "
+"suffix."
+msgstr "在创建摘要时,若内容因长度被截断,此项设置值将用作截断的结尾。"
+
+#: ../../settings.rst:326 df2e4e17f0de4d5b97f282fb9a73c57d
+msgid ""
+"If disabled, content with dates in the future will get a default status "
+"of ``draft``. See :ref:`reading_only_modified_content` for caveats."
+msgstr ""
+"若此项设为False,带了未来日期的文章或页面的状态都会设为 ``draft`` 。相关注意事项详见 "
+":ref:`reading_only_modified_content` 。"
+
+#: ../../settings.rst:331 32787a794f534c759cdff64b48f3d4f0
+msgid ""
+"Regular expression that is used to parse internal links. Default syntax "
+"when linking to internal files, tags, etc., is to enclose the identifier,"
+" say ``filename``, in ``{}`` or ``||``. Identifier between ``{`` and "
+"``}`` goes into the ``what`` capturing group. For details see :ref:`ref-"
+"linking-to-internal-content`."
+msgstr ""
+"用于解析内部链接的正则表达式。链接到内部文件、标签等时的默认语法是将标识符(例如 ``filename`` )括在 ``{}`` 或 ``||``"
+" 中。 ``{`` 和 ``}`` 之间的则进入 ``what`` 捕获组。更多详情请参见 :ref:`ref-linking-to-"
+"internal-content` 。"
+
+#: ../../settings.rst:339 58a95b3645534c8fa0d30d0e237f3d42
+msgid ""
+"A list of default Pygments settings for your reStructuredText code "
+"blocks. See :ref:`internal_pygments_options` for a list of supported "
+"options."
+msgstr ""
+"reStructuredText代码块的默认Pygments设置列表。有关受支持选项的列表,请参阅 "
+":ref:`internal_pygments_options` 。"
+
+#: ../../settings.rst:344 8086dcfa7a7c41dca8ad4c3bfca3f627
+msgid ""
+"If ``True``, saves content in caches. See "
+":ref:`reading_only_modified_content` for details about caching."
+msgstr "若设为 ``True`` ,会将内容保存在缓存中。有关缓存请参阅 :ref:`reading_only_modified_content` 。"
+
+#: ../../settings.rst:349 2ed178f518144b649b73718f9238b54b
+msgid ""
+"If set to ``'reader'``, save only the raw content and metadata returned "
+"by readers. If set to ``'generator'``, save processed content objects."
+msgstr "若设为 ``reader`` ,则只保存reader返回的原始内容和元数据。若设为 ``generator`` ,则保存处理过的内容对象。"
+
+#: ../../settings.rst:354 202ee8f7b97949909b28648926f42215
+msgid "Directory in which to store cache files."
+msgstr "指定存储缓存文件的目录。"
+
+#: ../../settings.rst:358 c4c1793569284f8aa087727d2cac0e4f
+msgid "If ``True``, use gzip to (de)compress the cache files."
+msgstr "若设为 ``True`` ,则使用gzip对缓存文件进行解压缩。"
+
+#: ../../settings.rst:362 3d8bcb7fb9fc4e0883de376634b5f443
+msgid "Controls how files are checked for modifications."
+msgstr "调整判定文件是否修改的方式"
+
+#: ../../settings.rst:364 ../../settings.rst:1364
+#: ded4e8033f904545a9ed73fe4b5f5912
+msgid "If set to ``'mtime'``, the modification time of the file is checked."
+msgstr "若设为 ``mtime`` ,则检查文件的修改时间。"
+
+#: ../../settings.rst:366 ../../settings.rst:1366
+#: 4e96ee3515e540ba828b8a80328ff700
+msgid ""
+"If set to a name of a function provided by the ``hashlib`` module, e.g. "
+"``'md5'``, the file hash is checked."
+msgstr "若设为 ``hashlib`` 库中提供的方法名,例如 ``md5`` ,则会检查文件的哈希值。"
+
+#: ../../settings.rst:371 2a66a13f76854ae794911f0c4d3fcffd
+msgid "If ``True``, load unmodified content from caches."
+msgstr "若设为 ``True`` ,则会从缓存中加载未修改的内容。"
+
+#: ../../settings.rst:375 eea621ea4a5344069cd4c2cf40b3a953
+msgid ""
+"A list of metadata fields containing reST/Markdown content to be parsed "
+"and translated to HTML."
+msgstr "元数据的列表,此列表中的元数据会被解析为HTML。"
+
+#: ../../settings.rst:380 8760f989d6ab474d987830631e1eca56
+msgid ""
+"The TCP port to serve content from the output folder via HTTP when "
+"pelican is run with --listen"
+msgstr "使用--listen运行pelican时,会在此选项指定的TCP端口上以HTTP提供内容。"
+
+#: ../../settings.rst:385 ea445f6d17204bd8b7f73803aa27a4a8
+msgid "The IP to which to bind the HTTP server."
+msgstr "需要和HTTP服务器绑定的IP地址。"
+
+#: ../../settings.rst:390 3b524d176da047c091f2769c156f3484
+msgid "URL settings"
+msgstr "URL设置"
+
+#: ../../settings.rst:392 fc094e521c5646b18a62975847740ce7
+msgid ""
+"The first thing to understand is that there are currently two supported "
+"methods for URL formation: *relative* and *absolute*. Relative URLs are "
+"useful when testing locally, and absolute URLs are reliable and most "
+"useful when publishing. One method of supporting both is to have one "
+"Pelican configuration file for local development and another for "
+"publishing. To see an example of this type of setup, use the ``pelican-"
+"quickstart`` script as described in the :doc:`Installation ` "
+"section, which will produce two separate configuration files for local "
+"development and publishing, respectively."
+msgstr ""
+"首先要知道的是,URL格式有两种形式: *相对URL* 、 *绝对URL* "
+"。相对URL在本地测试时往往比较有用,而绝对URL在发布时往往是比较有效可靠的。要同时支持两种URL形式,可以在本地开发和发布环境中使用两份不同的配置文件。执行脚本"
+" ``pelican-quickstart`` 时,就会为本地开发和发布环境分别生成一份配置文件,此脚本在 :doc:`安装Pelican "
+"` 一节中有详细描述。"
+
+#: ../../settings.rst:401 9749e4b4a85f45b28fa7a71d05b9bf9c
+msgid ""
+"You can customize the URLs and locations where files will be saved. The "
+"``*_URL`` and ``*_SAVE_AS`` variables use Python's format strings. These "
+"variables allow you to place your articles in a location such as "
+"``{slug}/index.html`` and link to them as ``{slug}`` for clean URLs (see "
+"example below). These settings give you the flexibility to place your "
+"articles and pages anywhere you want."
+msgstr ""
+"URL和文件存储位置都是可以自定义的, ``*_URL`` 和 ``*_SAVE_AS`` "
+"变量使用Python风格的格式化字符串。你可以利用一些变量将文章放在诸如 ``{slug}/index.html`` 的位置,并且可以以 "
+"``{slug}`` 的形式进行链接,如此可以让URL更加简洁(详见下面的例子)。这些设置可以让你灵活地将文章和页面放在任何你想要的地方。"
+
+#: ../../settings.rst:409 9e5d3f0ff133412b8d47de5fc9489e5f
+msgid ""
+"If a ``*_SAVE_AS`` setting contains a parent directory that doesn't match"
+" the parent directory inside the corresponding ``*_URL`` setting, this "
+"may cause Pelican to generate unexpected URLs in a few cases, such as "
+"when using the ``{attach}`` syntax."
+msgstr ""
+"如果 ``*_SAVE_AS`` 中包含了不在 ``*_URL`` 中的父目录,会导致Pelican在少数情况下(例如使用 "
+"``{attach}`` 语法时)产生不确定的URL。"
+
+#: ../../settings.rst:414 b2429a00d07341099c3f34b7134f3732
+msgid ""
+"If you don't want that flexibility and instead prefer that your generated"
+" output paths mirror your source content's filesystem path hierarchy, try"
+" the following settings::"
+msgstr "若不希望有这种灵活性,而是希望生成的输出路径保留源内容路径的层次结构,可以尝试以下设置:"
+
+#: ../../settings.rst:421 d89d44671c504501a54d3baca12e9017
+msgid ""
+"Otherwise, you can use a variety of file metadata attributes within URL-"
+"related settings:"
+msgstr "否则,可以在URL相关设置中可以使用下面的这些元数据属性:"
+
+#: ../../settings.rst:424 c97e4acb5b1d4ffda3028b9fdf8b7ed7
+msgid "slug"
+msgstr "slug"
+
+#: ../../settings.rst:425 a5257ea8cb0b430db73f09b337db7a74
+msgid "date"
+msgstr "date"
+
+#: ../../settings.rst:426 d6aa5650f1f34a0ba162f2fd2bf33182
+msgid "lang"
+msgstr "lang"
+
+#: ../../settings.rst:427 1fa0d7e3527b46e298468ad129188ca2
+msgid "author"
+msgstr "author"
+
+#: ../../settings.rst:428 e68b3eeb56304803b7dd56c5c919382d
+msgid "category"
+msgstr "category"
+
+#: ../../settings.rst:430 ../../settings.rst:565
+#: 663b3feef9aa44208752d6bbe79dbfba
+msgid "Example usage::"
+msgstr "例如:"
+
+#: ../../settings.rst:437 9cdacb3495c84888b48bb6092b7d0111
+msgid ""
+"This would save your articles into something like ``/posts/2011/Aug/07"
+"/sample-post/index.html``, save your pages into "
+"``/pages/about/index.html``, and render them available at URLs of "
+"``/posts/2011/Aug/07/sample-post/`` and ``/pages/about/``, respectively."
+msgstr ""
+"上面的设置会将你的文章以类似于 ``/posts/2011/Aug/07/sample-post/index.html`` 的形式存储,页面则以 "
+"``/pages/about/index.html`` 的形式存储,对应的URL分别为 ``/posts/2011/Aug/07/sample-"
+"post/`` 与 ``/pages/about/`` 。"
+
+#: ../../settings.rst:443 f7d6af3d02834a689522f5b479aa1d8b
+msgid ""
+"If you specify a ``datetime`` directive, it will be substituted using the"
+" input files' date metadata attribute. If the date is not specified for a"
+" particular file, Pelican will rely on the file's ``mtime`` timestamp. "
+"Check the `Python datetime documentation`_ for more information."
+msgstr ""
+"如果指定了 ``datetime`` 指令,会使用输入文件的日期元数据进行替换。若没有指定日期,Pelican会根据文件的 ``mtime`` "
+"时间戳替换之。更多信息可以参考 `Python datetime文档`_ 。"
+
+#: ../../settings.rst:453 6165ea3291b444c29b329cb7c1d12efa
+msgid ""
+"Defines whether Pelican should use document-relative URLs or not. Only "
+"set this to ``True`` when developing/testing and only if you fully "
+"understand the effect it can have on links/feeds."
+msgstr ""
+"定义Pelican是否使用文档间的相对URL。请只在开发或测试时将此项设为 ``True`` "
+",并且确保你已经明白此项设置对链接与feed的影响。(译者注:当此项为True时,网页之间的链接会使用相对路径表达,例如 ``../my-"
+"article.html`` )"
+
+#: ../../settings.rst:459 ef74181aff694f228072bb8fc114a49c
+msgid "The URL to refer to an article."
+msgstr "文章的URL格式。"
+
+#: ../../settings.rst:463 28debd5a396746ddaa4c5552034c6f5e
+msgid "The place where we will save an article."
+msgstr "文章的存储位置。"
+
+#: ../../settings.rst:467 a6a8e9c42b1144c0bbe071a0948a7c41
+msgid "The URL to refer to an article which doesn't use the default language."
+msgstr "非默认语言文章的URL格式。"
+
+#: ../../settings.rst:471 885589960b054edbac6b5b5ceabf70ba
+msgid ""
+"The place where we will save an article which doesn't use the default "
+"language."
+msgstr "非默认语言文章的存储位置。"
+
+#: ../../settings.rst:476 ed30016072a84eab9108c94ef05d72ac
+msgid "The URL to refer to an article draft."
+msgstr "draft状态文章的URL格式。"
+
+#: ../../settings.rst:480 f1827c2a350e41fb8a29b32ce4f0ce38
+msgid "The place where we will save an article draft."
+msgstr "draft状态文章的存储位置。"
+
+#: ../../settings.rst:484 a73fe74a021e4e1ca7b9d514b05dc709
+msgid ""
+"The URL to refer to an article draft which doesn't use the default "
+"language."
+msgstr "draft状态非默认语言文章的URL格式。"
+
+#: ../../settings.rst:488 9eaa92ef96bc49d3b7a751b88e7d1775
+msgid ""
+"The place where we will save an article draft which doesn't use the "
+"default language."
+msgstr "draft状态非默认语言文章的存储位置。"
+
+#: ../../settings.rst:493 303454f9d4524fc680dd2092dcb56cb9
+msgid "The URL we will use to link to a page."
+msgstr "页面的URL格式。"
+
+#: ../../settings.rst:497 afd8b970b616418d84b9e3fd4ab52cb4
+msgid ""
+"The location we will save the page. This value has to be the same as "
+"PAGE_URL or you need to use a rewrite in your server config."
+msgstr "页面的保存位置。除非在服务器上设置了重写规则,否则此项设置必须和PAGE_URL一致。"
+
+#: ../../settings.rst:502 311b0f44a40c450da8d5049aef066bed
+msgid ""
+"The URL we will use to link to a page which doesn't use the default "
+"language."
+msgstr "非默认语言页面的URL格式。"
+
+#: ../../settings.rst:507 a6829be9309144cebd8135f7e20f8670
+msgid "The location we will save the page which doesn't use the default language."
+msgstr "非默认语言页面的存储位置。"
+
+#: ../../settings.rst:511 95a46aad8dd046d096ad55df0777d67b
+msgid "The URL used to link to a page draft."
+msgstr "draft状态页面的URL。"
+
+#: ../../settings.rst:515 0036d550e0cc47058e209dcd9cf313b5
+msgid "The actual location a page draft is saved at."
+msgstr "draft状态页面的实际存储位置。"
+
+#: ../../settings.rst:519 6f382f91d09b4301b68a38d94312ef21
+msgid ""
+"The URL used to link to a page draft which doesn't use the default "
+"language."
+msgstr "draft状态非默认语言页面的URL格式。"
+
+#: ../../settings.rst:524 5ef1118bbfa844c5be60d015a8294deb
+msgid ""
+"The actual location a page draft which doesn't use the default language "
+"is saved at."
+msgstr "draft状态非默认语言页面的实际存储位置。"
+
+#: ../../settings.rst:529 4c23c58e9b0341c7a632114822383784
+msgid "The URL to use for an author."
+msgstr "某一个作者的URL格式。"
+
+#: ../../settings.rst:533 26e5bbec4ccf442eb1f2ed5850b10aab
+msgid "The location to save an author."
+msgstr "某一个作者的存储位置。"
+
+#: ../../settings.rst:537 1a63d575005147a6a1f506499aea31da
+msgid "The URL to use for a category."
+msgstr "某一个分类的URL格式。"
+
+#: ../../settings.rst:541 aae69f204db3414eb520a6cf2d7b9ee0
+msgid "The location to save a category."
+msgstr "某一个分类的存储位置。"
+
+#: ../../settings.rst:545 c248088861924e30beb1d223ec197ff5
+msgid "The URL to use for a tag."
+msgstr "某一个标签的URL格式。"
+
+#: ../../settings.rst:549 c6f5770301c44f3abb9c105276cb9bd3
+msgid "The location to save the tag page."
+msgstr "某一个标签的存储位置"
+
+#: ../../settings.rst:553 9fc1cb3d807d407bbff78d4d3203f8c0
+msgid ""
+"If you do not want one or more of the default pages to be created (e.g., "
+"you are the only author on your site and thus do not need an Authors "
+"page), set the corresponding ``*_SAVE_AS`` setting to ``''`` to prevent "
+"the relevant page from being generated."
+msgstr "如果您不希望创建默认页面(例如你是网站上的唯一作者,因此不需要作者页面),请将相应的 ``*_SAVE_AS`` 设置设置为 ``''`` 。"
+
+#: ../../settings.rst:558 2a4afa6f1db840c69e80199d928c3e9a
+msgid ""
+"Pelican can optionally create per-year, per-month, and per-day archives "
+"of your posts. These secondary archives are disabled by default but are "
+"automatically enabled if you supply format strings for their respective "
+"``_SAVE_AS`` settings. Period archives fit intuitively with the "
+"hierarchical model of web URLs and can make it easier for readers to "
+"navigate through the posts you've written over time."
+msgstr ""
+"可选的,Pelican可以为帖子创建每年、每月或是每日的归档。除非你为各自的 ``*_SAVE_AS`` "
+"设置了格式化字符串,否则这些归档在默认情况下是关闭的。按时间进行归档更直观地符合web URL的层次模型,也可以让读者更容易按时间顺序浏览帖子。"
+
+#: ../../settings.rst:572 973812c7673a481686350dfca8378df8
+msgid ""
+"With these settings, Pelican will create an archive of all your posts for"
+" the year at (for instance) ``posts/2011/index.html`` and an archive of "
+"all your posts for the month at ``posts/2011/Aug/index.html``. These can "
+"be accessed through the URLs ``posts/2011/`` and ``posts/2011/Aug/``, "
+"respectively."
+msgstr ""
+"例如若使用了上面的设置,Pelican会创建按年的归档(例如 ``posts/2011/index.html`` ),以及按月的归档(例如 "
+"``posts/2011/Aug/index.html`` )。这两个页面分别通过 ``posts/2011/`` 和 "
+"``posts/2011/Aug/`` 进行访问。"
+
+#: ../../settings.rst:578 e1e1bb5cc26a40a9a62f88ddd10c072a
+msgid ""
+"Period archives work best when the final path segment is ``index.html``. "
+"This way a reader can remove a portion of your URL and automatically "
+"arrive at an appropriate archive of posts, without having to specify a "
+"page name."
+msgstr ""
+"当路径设置为以 ``index.html`` "
+"结尾时,归档的体验会非常好。读者可以删除URL中的一部分以到达合适时间段的归档,而不需要指定某一个页面的名称。"
+
+#: ../../settings.rst:584 4899822fdcf94a7e8edb0478260181a5
+msgid "The location to save per-year archives of your posts."
+msgstr "年归档的存储位置。"
+
+#: ../../settings.rst:588 eaac63d4c2aa4a0dbfe548b61008edfe
+msgid ""
+"The URL to use for per-year archives of your posts. You should set this "
+"if you enable per-year archives."
+msgstr "年归档的URL格式,若想要启用年归档,请配置此项。"
+
+#: ../../settings.rst:593 376c3ee871c847d7b1072ed0e29c482a
+msgid "The location to save per-month archives of your posts."
+msgstr "月归档的存储位置。"
+
+#: ../../settings.rst:597 4788e190048c48c181a8aa4b60b86535
+msgid ""
+"The URL to use for per-month archives of your posts. You should set this "
+"if you enable per-month archives."
+msgstr "月归档的URL格式,若想要启用月归档,请配置此项。"
+
+#: ../../settings.rst:602 9e0023d2bb9c43d3bc7bad9bf4b5429c
+msgid "The location to save per-day archives of your posts."
+msgstr "日归档的存储位置。"
+
+#: ../../settings.rst:606 3055e7f7b4af4e87aca8cb560dd0313c
+msgid ""
+"The URL to use for per-day archives of your posts. You should set this if"
+" you enable per-day archives."
+msgstr "日归档的URL格式,若想要启用日归档,请配置此项。"
+
+#: ../../settings.rst:609 67fdf1f1cf1a497b8c5847fb10d907e1
+msgid ""
+"``DIRECT_TEMPLATES`` work a bit differently than noted above. Only the "
+"``_SAVE_AS`` settings are available, but it is available for any direct "
+"template."
+msgstr ""
+"``DIRECT_TEMPLATES`` 的工作方式与上面提到的有点不同,在其中可以使用一些特别的直接模板,并且仅在 ``*_SAVE_AS`` "
+"设置中可用。"
+
+#: ../../settings.rst:615 ee557971709e4c8e84085295064a205e
+msgid "The location to save the article archives page."
+msgstr "文章归档页面的存储位置。"
+
+#: ../../settings.rst:619 5229274ff3514aa2b3ab5338b22cdea6
+msgid "The location to save the author list."
+msgstr "作者列表的存储位置。"
+
+#: ../../settings.rst:623 560b6eaf36ef4975a5f7503698473e2b
+msgid "The location to save the category list."
+msgstr "分类列表的存储位置。"
+
+#: ../../settings.rst:627 048f18adc37f4693925f05373a426f26
+msgid "The location to save the tag list."
+msgstr "标签列表的存储位置。"
+
+#: ../../settings.rst:631 ac31a8a0b68d47ed9ec65dc9b8eae2a6
+msgid "The location to save the list of all articles."
+msgstr "所有文章列表的存储位置。"
+
+#: ../../settings.rst:633 ceb51d0a532447099bc681ba9cce5b1d
+msgid ""
+"URLs for direct template pages are theme-dependent. Some themes use "
+"corresponding ``*_URL`` setting as string, while others hard-code them: "
+"``'archives.html'``, ``'authors.html'``, ``'categories.html'``, "
+"``'tags.html'``."
+msgstr ""
+"事实上,直接模板页面的URL是和使用的主题相关的。有些主题会使用 ``*_URL`` 作为变量字符串,而有些则是直接对这些直接模板页面进行硬编码:"
+" ``'archives.html'`` 、 ``'authors.html'`` 、 ``'categories.html'`` 。"
+
+#: ../../settings.rst:640 d600dab1b91c4662833d0c5c298938b4
+msgid ""
+"Specifies from where you want the slug to be automatically generated. Can"
+" be set to ``title`` to use the \"Title:\" metadata tag or ``basename`` "
+"to use the article's file name when creating the slug."
+msgstr "自动生成slug所依赖的内容。可以指定为元数据标签 ``title`` ,也可以使用文章源文件的文件名 ``basename`` 。"
+
+#: ../../settings.rst:646 d274502af37648e289fd588834b0019d
+msgid ""
+"Allow Unicode characters in slugs. Set ``True`` to keep Unicode "
+"characters in auto-generated slugs. Otherwise, Unicode characters will be"
+" replaced with ASCII equivalents."
+msgstr ""
+"指定是否允许在slug中使用Unicode字符。若设为 ``True`` "
+",自动生成的slug中会保留Unicode字符;否则Unicode字符会使用含义相同的ASCII替换。"
+
+#: ../../settings.rst:652 37cddacc30bc430b9ea1bad479e90f3d
+msgid ""
+"Preserve uppercase characters in slugs. Set ``True`` to keep uppercase "
+"characters from ``SLUGIFY_SOURCE`` as-is."
+msgstr "指定是否保留slug中的大写字母。若设为 ``True`` ,则会原样保留 ``SLUGIFY_SOURCE`` 中的大写字母。"
+
+#: ../../settings.rst:662 785ff8b6508b4e6e980ae6638e7346f9
+msgid ""
+"Regex substitutions to make when generating slugs of articles and pages. "
+"Specified as a list of pairs of ``(from, to)`` which are applied in "
+"order, ignoring case. The default substitutions have the effect of "
+"removing non-alphanumeric characters and converting internal whitespace "
+"to dashes. Apart from these substitutions, slugs are always converted to "
+"lowercase ascii characters and leading and trailing whitespace is "
+"stripped. Useful for backward compatibility with existing URLs."
+msgstr ""
+"指定生成文章和页面slug时要进行的正则表达式替换。指定的是一对对 ``(from, to)`` "
+"(from为要替换的内容,to为替换进去的内容),列表中的各对替换规则是按序执行且忽略大小写的。默认的替换会删除非字母非数字的字符并将内部空格替换为连字符。除此之外,slug会将所有字符转换为小写ASCII字符,并删除所有前导和末尾空格。这有利于现有URL的向后兼容。"
+
+#: ../../settings.rst:672 f2ddbe0d79124ce2b0b9390f9c1492e9
+msgid ""
+"Regex substitutions for author slugs. Defaults to "
+"``SLUG_REGEX_SUBSTITUTIONS``."
+msgstr "针对作者slug的正则替换。默认等于 ``SLUG_REGEX_SUBSTITUTIONS`` 。"
+
+#: ../../settings.rst:677 68c5594a14544fe9bed90cdfb41f25c4
+msgid ""
+"Regex substitutions for category slugs. Defaults to "
+"``SLUG_REGEX_SUBSTITUTIONS``."
+msgstr "针对分类slug的正则替换。默认等于 ``SLUG_REGEX_SUBSTITUTIONS`` 。"
+
+#: ../../settings.rst:682 3dd263d38e47445c88d34a790e919053
+msgid ""
+"Regex substitutions for tag slugs. Defaults to "
+"``SLUG_REGEX_SUBSTITUTIONS``."
+msgstr "针对标签slug的正则替换。默认等于 ``SLUG_REGEX_SUBSTITUTIONS`` 。"
+
+#: ../../settings.rst:685 21a264926d3b46edb2af35f936d0985a
+msgid "Time and Date"
+msgstr "日期与时间"
+
+#: ../../settings.rst:689 ef50be008f104aa6bcbf2df6a81921e8
+msgid "The timezone used in the date information, to generate Atom and RSS feeds."
+msgstr "日期信息中使用的时区,会用于生成Atom和RSS feeds。(无默认值,必须手动设置指定)"
+
+#: ../../settings.rst:691 9ec4050abc58489db63deda401d80b7d
+msgid ""
+"If no timezone is defined, UTC is assumed. This means that the generated "
+"Atom and RSS feeds will contain incorrect date information if your locale"
+" is not UTC."
+msgstr "若没有定义时区,会直接使用UTC时区。这意味着当你的时区不等于UTC时,生成的Atom和RSS feeds中会包含错误的日期信息。"
+
+#: ../../settings.rst:695 8797378878dc47e99388e1d0421da263
+msgid ""
+"Pelican issues a warning in case this setting is not defined, as it was "
+"not mandatory in previous versions."
+msgstr "在之前的版本中,这一项设置并不是强制的,因此Pelican会在未设置时区时提出警告。"
+
+#: ../../settings.rst:698 18326d528d0045c88c8e31d0f9bb26f9
+msgid ""
+"Have a look at `the wikipedia page`_ to get a list of valid timezone "
+"values."
+msgstr "有效的时区设置值可以在 `维基百科页`_ 中查看。"
+
+#: ../../settings.rst:704 3af0a717e34c4926a40fc6cd58518df2
+msgid ""
+"The default date you want to use. If ``'fs'``, Pelican will use the file"
+" system timestamp information (mtime) if it can't get date information "
+"from the metadata. If given any other string, it will be parsed by the "
+"same method as article metadata. If set to a tuple object, the default "
+"datetime object will instead be generated by passing the tuple to the "
+"``datetime.datetime`` constructor."
+msgstr ""
+"要使用的默认日期。若设为 ``'fs'`` "
+",Pelican在无法从元数据中获取日期时,会以系统时间戳信息(mtime)为准;若设为其他字符串,Pelican将用与解析文章元数据相同的方法进行解析;若设为元组,则会将该元组传递给"
+" ``datetime.datetime`` 的构造函数来生成日期。"
+
+#: ../../settings.rst:713 e8358468fd034f24a7984b20909ada30
+msgid "The default date format you want to use."
+msgstr "指定要使用的默认日期格式。"
+
+#: ../../settings.rst:717 e7f8237ab45945d78484e8fef0005bdc
+msgid "If you manage multiple languages, you can set the date formatting here."
+msgstr "若需要管理多种语言,可以在这里针对不同语言设置不同的日期格式。"
+
+#: ../../settings.rst:719 eab2352e48174cb085b7bd23115ad15b
+msgid ""
+"If no ``DATE_FORMATS`` are set, Pelican will fall back to "
+"``DEFAULT_DATE_FORMAT``. If you need to maintain multiple languages with "
+"different date formats, you can set the ``DATE_FORMATS`` dictionary using"
+" the language name (``lang`` metadata in your post content) as the key."
+msgstr ""
+"如果 ``DATE_FORMATS`` 没有设置过,Pelican会使用 ``DEFAULT_DATE_FORMAT`` "
+"。如果要为不同语言设置不同如期格式,可以在此设置项字典中指定,键为语言名称(对应于帖子内容元数据中的 ``lang`` ),值为日期格式字符串。"
+
+#: ../../settings.rst:724 2f8d1e03399549bf84a05e25d718ec80
+#, python-format
+msgid ""
+"In addition to the standard C89 strftime format codes that are listed in "
+"`Python datetime documentation`_, you can use the ``-`` character between"
+" ``%`` and the format character to remove any leading zeros. For example,"
+" ``%d/%m/%Y`` will output ``01/01/2014`` whereas ``%-d/%-m/%Y`` will "
+"result in ``1/1/2014``."
+msgstr ""
+"除了 `Python datetime文档`_ 中列出的标准C89 strftime格式代码之外,可以通过在 ``%`` 和格式字符之间添加 "
+"``-`` 来删除日期中的前导零。例如 ``%d/%m/%Y`` 对应输出 ``01/01/2014`` ,而 ``%-d/%-m/%Y`` "
+"对应输出 ``1/1/2014`` 。"
+
+#: ../../settings.rst:737 28f1a04cc72943b8bbb45b0f05039e6b
+msgid ""
+"It is also possible to set different locale settings for each language by"
+" using a ``(locale, format)`` tuple as a dictionary value which will "
+"override the ``LOCALE`` setting:"
+msgstr "你还能够通过将元组 ``(locale, format)`` 作为值,来为每种语言指定地区,此处设置的地区会覆盖 ``LOCALE`` 设置:"
+
+#: ../../settings.rst:757 0edf14c3edcf41aba562d74822a9f1f5
+msgid ""
+"Change the locale [#]_. A list of locales can be provided here or a "
+"single string representing one locale. When providing a list, all the "
+"locales will be tried until one works."
+msgstr "设置地区 [#]_ 。可以同时指定多个地区,也可以使用字符串指定单个地区。当设置了多个地区时,会一个个尝试直到某一个可以使用。"
+
+#: ../../settings.rst:761 26b26ebd973b40fd973a9252fe24173c
+msgid "You can set locale to further control date format:"
+msgstr "通过设置地区进一步控制日期格式:"
+
+#: ../../settings.rst:769 e0056e0a853f4891b87e3b2f66af9ab9
+msgid ""
+"For a list of available locales refer to `locales on Windows`_ or on "
+"Unix/Linux, use the ``locale -a`` command; see manpage `locale(1)`_ for "
+"more information."
+msgstr ""
+"要查看可用的地区列表,可以参看 `Windows上的地区`_ ;若使用的时Unix/Linux系统, 使用 ``locale -a`` "
+"命令即可,有关该命令的更多信息可以参阅手册 `locale(1)`_ 。"
+
+#: ../../settings.rst:774 ac7d9e8b711e438e9a80a31274d1fa11
+msgid "Default is the system locale."
+msgstr "默认值与系统的地区设置保持一致。"
+
+#: ../../settings.rst:788 39a1ce7f77994c1ca37792f44b4297ee
+msgid "Template pages"
+msgstr "模板页面"
+
+#: ../../settings.rst:792 fb2c9cf72b3946828619ecb6051abd0b
+msgid ""
+"A mapping containing template pages that will be rendered with the blog "
+"entries."
+msgstr "一些映射关系,指出了会和博客一起渲染的模板页面。"
+
+#: ../../settings.rst:795 f8163db87b30489fa6067f58d395cee1
+msgid ""
+"If you want to generate custom pages besides your blog entries, you can "
+"point any Jinja2 template file with a path pointing to the file and the "
+"destination path for the generated file."
+msgstr "如果你想要生成除了博客之外的自定义页面,你可以指出任何Jinja2的模板文件,需要同时指出源文件路径和生成文件的路径。"
+
+#: ../../settings.rst:799 ef26f9eaad274b969a0ae1183e7ac0c8
+msgid ""
+"For instance, if you have a blog with three static pages — a list of "
+"books, your resume, and a contact page — you could have::"
+msgstr "例如,如果你的博客有三个静态页面——书籍列表、你的简历、以及一个联系我们页面,你可这么配置:"
+
+#: ../../settings.rst:808 2c8a293e4d77423db215de89aa20ca5c
+msgid "The extensions to use when looking up template files from template names."
+msgstr "指定要查找并视为模板文件的文件扩展名。"
+
+#: ../../settings.rst:812 101a0198fc6249b3adea735ff522b9b1
+msgid ""
+"List of templates that are used directly to render content. Typically "
+"direct templates are used to generate index pages for collections of "
+"content (e.g., category and tag index pages). If the author, category and"
+" tag collections are not needed, set ``DIRECT_TEMPLATES = ['index', "
+"'archives']``"
+msgstr ""
+"指定用于直接渲染内容的模板列表。一般来说直接模板会用于生成内容集合的主页(例如分类和标签的主页)。如果不需要作者、分类或者标签集合,可以设置 "
+"``DIRECT_TEMPLATES = ['index', archives']`` 。"
+
+#: ../../settings.rst:817 c5952388671a4fab8095d4a9b596905f
+msgid ""
+"``DIRECT_TEMPLATES`` are searched for over paths maintained in "
+"``THEME_TEMPLATES_OVERRIDES``."
+msgstr "``DIRECT_TEMPLATES`` 会在 ``THEME_TEMPLATES_OVERRIDES`` 的路径中搜索。"
+
+#: ../../settings.rst:822 8c4e0bfebc60422cbcb852f17e53fbeb
+msgid "Metadata"
+msgstr "元数据"
+
+#: ../../settings.rst:826 5d3ac5fa0fe94d0faf3603d032152259
+msgid "Default author (usually your name)."
+msgstr "默认作者(通常是你自己的名字)。"
+
+#: ../../settings.rst:830 bd855c810143419b97250e11fe9db428
+msgid "The default metadata you want to use for all articles and pages."
+msgstr "应用于所有文章和页面的默认元数据。"
+
+#: ../../settings.rst:834 b9b192605075405ba1b89c817db323e5
+msgid ""
+"The regexp that will be used to extract any metadata from the filename. "
+"All named groups that are matched will be set in the metadata object. "
+"The default value will only extract the date from the filename."
+msgstr "指定用于从文件名中提取元数据的正则表达式。所有匹配上的命名匹配组都会用于设置元数据。默认值会从文件名中提取日期。"
+
+#: ../../settings.rst:838 f5730036a8ad4bdbbc7250201e97d4b3
+msgid "For example, to extract both the date and the slug::"
+msgstr "例如,可以同时提取日期和slug:"
+
+#: ../../settings.rst:842 bfcc4210a493460a954dfb5d96f57462
+msgid "See also ``SLUGIFY_SOURCE``."
+msgstr "另请参看 ``SLUGIFY_SOURCE`` 。"
+
+#: ../../settings.rst:846 1bc373d7947b4c9181fd54d01409eb06
+msgid ""
+"Like ``FILENAME_METADATA``, but parsed from a page's full path relative "
+"to the content source directory."
+msgstr "和 ``FILENAME_METADATA`` 类似,但提取解析的对象是相对于内容源文件目录的路径。"
+
+#: ../../settings.rst:851 b02a8c4b99204d92b9d6625f79c27c89
+msgid ""
+"Extra metadata dictionaries keyed by relative path. Relative paths "
+"require correct OS-specific directory separators (i.e. / in UNIX and \\\\"
+" in Windows) unlike some other Pelican file settings. Paths to a "
+"directory apply to all files under it. The most-specific path wins "
+"conflicts."
+msgstr "指定要从相对路径提取的额外元数据字典。与Pelican的其他设置文件不同,此项设置需要正确使用和操作系统对应的目录分隔符(Unix中使用/,Windows中使用\\\\)。若对一个目录设置了规则,该规则会作用于该目录下所有文件。当有多个路径相互冲突时,Pelican会选用更为具体的路径。"
+
+#: ../../settings.rst:856 d8ceeec6c7e14be3a79c73db2472a7cb
+msgid ""
+"Not all metadata needs to be :ref:`embedded in source file itself "
+"`. For example, blog posts are often named following a"
+" ``YYYY-MM-DD-SLUG.rst`` pattern, or nested into ``YYYY/MM/DD-SLUG`` "
+"directories. To extract metadata from the filename or path, set "
+"``FILENAME_METADATA`` or ``PATH_METADATA`` to regular expressions that "
+"use Python's `group name notation`_ ``(?P…)``. If you want to "
+"attach additional metadata but don't want to encode it in the path, you "
+"can set ``EXTRA_PATH_METADATA``:"
+msgstr ""
+"不是所有元数据都需要直接 :ref:`放在推文源文件中 ` 。例如,博文可能是以 ``YYYY-MM-DD-"
+"SLUG.rst`` 的形式命名的,或者是直接放在 ``YYYY/MM/DD-SLUG`` 文件夹中。要从文件名或路径中提取元数据,设置 "
+"``FILENAME_METADATA`` 或 ``PATH_METADATA`` 即可,需使用Python风格的 `命名组表示法`_ "
+"``(?P…)`` 。当你需要为帖子附加一些额外的元数据,但不想将其编码在文件路径中时,就可以在 "
+"``EXTRA_PATH_METADATA`` 中设置:"
+
+#: ../../settings.rst:877 3c7085d581f74cba8b5b7be5451d0dd0
+msgid ""
+"This can be a convenient way to shift the installed location of a "
+"particular file:"
+msgstr "通过这个设置项,很方便就可以转移特定文件的位置:"
+
+#: ../../settings.rst:897 62d0261aa15a42a486691e7d615f58c7
+msgid "Feed settings"
+msgstr "订阅源设置"
+
+#: ../../settings.rst:899 e06e3b6cd4e34d9990e28f533c70916b
+msgid ""
+"By default, Pelican uses Atom feeds. However, it is also possible to use "
+"RSS feeds if you prefer."
+msgstr "默认情况下,Pelican会使用Atom订阅源。但如果你愿意的话,也可以使用RSS。"
+
+#: ../../settings.rst:902 8a0de4febfd34d9eb1cdcc74d4c02198
+msgid ""
+"Pelican generates category feeds as well as feeds for all your articles. "
+"It does not generate feeds for tags by default, but it is possible to do "
+"so using the ``TAG_FEED_ATOM`` and ``TAG_FEED_RSS`` settings:"
+msgstr ""
+"Pelican会生成分类的feed,也会为所有文章生成,但默认并不会为标签生成feed,要生成标签feed,可以使用 "
+"``TAG_FEED_ATOM`` 和 ``TAG_FEED_RSS`` 设置:"
+
+#: ../../settings.rst:908 e1d650d03db342a09b22e34ff11b9365
+msgid ""
+"The domain prepended to feed URLs. Since feed URLs should always be "
+"absolute, it is highly recommended to define this (e.g., "
+"\"https://feeds.example.com\"). If you have already explicitly defined "
+"SITEURL (see above) and want to use the same domain for your feeds, you "
+"can just set: ``FEED_DOMAIN = SITEURL``."
+msgstr ""
+"指定要附加到订阅源URL前面的域名。因为订阅源URL最好是绝对的,所以强烈推荐定义此设置项(例如 "
+"https://feeds.example.com )。若SITEURL已经显式地定义了,并且希望使用相同地URL,就可以直接设置 "
+"``FEED_DOMAIN = SITEURL`` 。"
+
+#: ../../settings.rst:916 f3bc5a60dab54c2ab52f99f81b743102
+msgid "The location to save the Atom feed."
+msgstr "指定保存Atom订阅源的位置。"
+
+#: ../../settings.rst:920 4145c00c2347484fa37f4387283e0fb6
+msgid ""
+"Relative URL of the Atom feed. If not set, ``FEED_ATOM`` is used both for"
+" save location and URL."
+msgstr "Atom订阅源的相对URL。如果未设置此项,会将 ``FEED_ATOM`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:925 579cd1112ba44be7b82c77050af3a256
+msgid "The location to save the RSS feed."
+msgstr "指定保存RSS订阅源的位置。"
+
+#: ../../settings.rst:929 5fdb4ce14c0a454381db194885b088f2
+msgid ""
+"Relative URL of the RSS feed. If not set, ``FEED_RSS`` is used both for "
+"save location and URL."
+msgstr "RSS订阅源的相对URL。如果未设置此项,会将 ``FEED_RSS`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:934 91bd81a74c234968a27e4b61924273f5
+msgid ""
+"The location to save the all-posts Atom feed: this feed will contain all "
+"posts regardless of their language."
+msgstr "存储all-posts Atom订阅源的文件位置:其中会包含所有语言的帖子。"
+
+#: ../../settings.rst:939 62aceff0073b48eeb8929f102bfad7e4
+msgid ""
+"Relative URL of the all-posts Atom feed. If not set, ``FEED_ALL_ATOM`` is"
+" used both for save location and URL."
+msgstr "all-posts Atom订阅源的相对URL。如果未设置此项,会将 ``FEED_ALL_ATOM`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:944 3b9f640128e84a4a96e696a830e3a8cd
+msgid ""
+"The location to save the the all-posts RSS feed: this feed will contain "
+"all posts regardless of their language."
+msgstr "存储all-posts RSS订阅源的文件位置:其中会包含所有语言的帖子。"
+
+#: ../../settings.rst:949 2b80018af24945ac949377bb01f4d699
+msgid ""
+"Relative URL of the all-posts RSS feed. If not set, ``FEED_ALL_RSS`` is "
+"used both for save location and URL."
+msgstr "all-posts RSS订阅源的相对URL。如果未设置此项,会将 ``FEED_ALL_RSS`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:954 c00dc056edc64aafb33bafad947364db
+msgid "The location to save the category Atom feeds. [2]_"
+msgstr "category Atom订阅源的存储位置。 [2]_"
+
+#: ../../settings.rst:958 fb8c09a3eb844121b05c5a067d616a42
+msgid ""
+"Relative URL of the category Atom feeds, including the ``{slug}`` "
+"placeholder. [2]_ If not set, ``CATEGORY_FEED_ATOM`` is used both for "
+"save location and URL."
+msgstr ""
+"category Atom订阅源的相对URL,其中包含 ``{slug}`` 。 [2]_ 如果未设置, 会将 "
+"``CATEGORY_FEED_ATOM`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:964 bd0dba597ed44c0ab95df015d13fb42f
+msgid ""
+"The location to save the category RSS feeds, including the ``{slug}`` "
+"placeholder. [2]_"
+msgstr "category RSS订阅源的存储位置,其中包含 ``{slug}`` 。 [2]_"
+
+#: ../../settings.rst:969 5e06453a1300407188c78eceadcabef1
+msgid ""
+"Relative URL of the category RSS feeds, including the ``{slug}`` "
+"placeholder. [2]_ If not set, ``CATEGORY_FEED_RSS`` is used both for save"
+" location and URL."
+msgstr ""
+"category RSS订阅源的相对URL,其中包含 ``{slug}`` 。 [2]_ 如果未设置, 会将 "
+"``CATEGORY_FEED_RSS`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:975 1ad2208106b5492cbc0bb0fc6b6d2eef
+msgid "The location to save the author Atom feeds. [2]_"
+msgstr "category Atom订阅源的存储位置,其中包含 ``{slug}`` 。 [2]_"
+
+#: ../../settings.rst:979 069eb238b2d6458eac8fc200c12aa6fd
+msgid ""
+"Relative URL of the author Atom feeds, including the ``{slug}`` "
+"placeholder. [2]_ If not set, ``AUTHOR_FEED_ATOM`` is used both for save "
+"location and URL."
+msgstr ""
+"author Atom订阅源的相对URL,其中包含 ``{slug}`` 。 [2]_ 如果未设置, 会将 "
+"``AUTHOR_FEED_ATOM`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:985 0b5a562410eb47c5a47a31a852973974
+msgid "The location to save the author RSS feeds. [2]_"
+msgstr "author RSS订阅源的存储位置,其中包含 ``{slug}`` 。 [2]_"
+
+#: ../../settings.rst:989 c1964676a205466fb2a835e99bc00885
+msgid ""
+"Relative URL of the author RSS feeds, including the ``{slug}`` "
+"placeholder. [2]_ If not set, ``AUTHOR_FEED_RSS`` is used both for save "
+"location and URL."
+msgstr ""
+"author RSS订阅源的相对URL,其中包含 ``{slug}`` 。 [2]_ 如果未设置, 会将 ``AUTHOR_FEED_RSS`` "
+"同时用于存储位置和URL。"
+
+#: ../../settings.rst:994 2242bd16e270495eba740e72964d840d
+msgid ""
+"The location to save the tag Atom feed, including the ``{slug}`` "
+"placeholder. [2]_"
+msgstr "tag Atom订阅源的存储位置,其中包含 ``{slug}`` 。 [2]_"
+
+#: ../../settings.rst:999 2f69bb73cef343b48f09ead8fd268d26
+msgid ""
+"Relative URL of the tag Atom feed, including the ``{slug}`` placeholder. "
+"[2]_"
+msgstr "tag Atom订阅源的相对URL,其中包含 ``{slug}`` 。 [2]_"
+
+#: ../../settings.rst:1004 059a551f316c4d7e99b43a4d6e999c43
+msgid ""
+"Relative URL to output the tag RSS feed, including the ``{slug}`` "
+"placeholder. If not set, ``TAG_FEED_RSS`` is used both for save location "
+"and URL."
+msgstr "tag RSS订阅源的相对URL,其中包含 ``{slug}`` 。如果未设置,会将 ``TAG_FEED_RSS`` 同时用于存储位置和URL。"
+
+#: ../../settings.rst:1010 ba1909bb43f7468ab36384a33e9f0d35
+msgid ""
+"Maximum number of items allowed in a feed. Setting to ``None`` will cause"
+" the feed to contains every article. 100 if not specified."
+msgstr "单个订阅源中允许包含的最多元素数量。若设为 ``None`` 表示不做上限;若不指定,默认上限为100。"
+
+#: ../../settings.rst:1015 ee56a7f7761e4badb24ddd0771b9bcaa
+msgid ""
+"Only include item summaries in the ``description`` tag of RSS feeds. If "
+"set to ``False``, the full content will be included instead. This setting"
+" doesn't affect Atom feeds, only RSS ones."
+msgstr ""
+"仅在RSS订阅源的 ``description`` 标签中包含项目摘要。若设为 ``False`` ,则将包含完整内容。此项设置不会影响Atom "
+"feed,只针对RSS feed。"
+
+#: ../../settings.rst:1021 d34b3c9cf9c643559e8f1bd58b4d4d9e
+msgid ""
+"If set to ``True``, ``?ref=feed`` will be appended to links in generated "
+"feeds for the purpose of referrer tracking."
+msgstr "若设为 ``True`` ,会将 ``?ref=feed`` 附到生成的链接中,以便追踪引用。"
+
+#: ../../settings.rst:1024 67aa494bb5c846eeac10b91d633fbeb1
+msgid ""
+"If you don't want to generate some or any of these feeds, set the above "
+"variables to ``None``."
+msgstr "若你不想要生成某些订阅源,将对应变量设为 ``None`` 即可。"
+
+#: ../../settings.rst:1027 e281a7a6d60d4362a56364ea4e7c2ed4
+msgid "``{slug}`` is replaced by name of the category / author / tag."
+msgstr "``{slug}`` 会分别用分类名/作者名/标签名来替换。"
+
+#: ../../settings.rst:1031 f1101bee785f48fb8745c1cbed7ccb5c
+msgid "Pagination"
+msgstr "分页"
+
+#: ../../settings.rst:1033 9d8deaf84be143aa919bae8458e256a5
+msgid ""
+"The default behaviour of Pelican is to list all the article titles along "
+"with a short description on the index page. While this works well for "
+"small-to-medium sites, sites with a large quantity of articles will "
+"probably benefit from paginating this list."
+msgstr "默认情况下,Pelican会把所有文章以简短描述的形式展示在首页上。虽然这对中小型网站效果不错,但对于拥有大量文章的网站来说可能需要将此列表进行分页。"
+
+#: ../../settings.rst:1038 8315da9ec0d64ffb881d0dfa6f25590e
+msgid "You can use the following settings to configure the pagination."
+msgstr "你可以使用下面的设置来配置分页。"
+
+#: ../../settings.rst:1042 9a56cc2f10634c34980a6868c4988e43
+msgid ""
+"The minimum number of articles allowed on the last page. Use this when "
+"you don't want the last page to only contain a handful of articles."
+msgstr "最后一页允许的最小文章数。当不希望最后一页仅包含少数文章时,请使用此选项。(译者注:当最后一页达不到此最小文章数时,会被合并到前一页)"
+
+#: ../../settings.rst:1047 f3d093d68890442abfda1dea23eb25ed
+msgid ""
+"The maximum number of articles to include on a page, not including "
+"orphans. False to disable pagination."
+msgstr "一个页面上包含的最大文章数,不包括孤立文章(译者注:当发生上一条设置选项中提到的合并时,最后一页显然会超过此最大文章数)。设为False会禁用分页。"
+
+#: ../../settings.rst:1052 df3fe4f1806f4a16b2a9fdd11cc50aa2
+msgid ""
+"The templates to use pagination with, and the number of articles to "
+"include on a page. If this value is ``None``, it defaults to "
+"``DEFAULT_PAGINATION``."
+msgstr "指定哪些模板需要启用分页,以及对应的单页面文章数量。若设为 ``None`` ,则默认值为 ``DEFAULT_PAGINATION`` 。"
+
+#: ../../settings.rst:1060 0ee1f92f0be740c3afb7b793327495df
+msgid "A set of patterns that are used to determine advanced pagination output."
+msgstr "一组模式,用于高级分页输出。"
+
+#: ../../settings.rst:1064 1a3aef30d05c45b5b4dd54ab7c4c043c
+msgid "Using Pagination Patterns"
+msgstr "使用分页模式"
+
+#: ../../settings.rst:1066 9bbd095189634b8f8a43cf4f196ec8d5
+msgid ""
+"By default, pages subsequent to ``.../foo.html`` are created as "
+"``.../foo2.html``, etc. The ``PAGINATION_PATTERNS`` setting can be used "
+"to change this. It takes a sequence of triples, where each triple "
+"consists of::"
+msgstr ""
+"默认情况下,连续页面的URL会如此编码:第一页为 ``.../foo.html`` ,后一页为 ``.../foo2.html`` "
+"。``PAGINATION_PATTERNS`` 就是用于修改这个编页规则的,其中是一些三元组:"
+
+#: ../../settings.rst:1072 9303664b0829486097906d555b50c30d
+msgid ""
+"For ``page_url`` and ``page_save_as``, you may use a number of variables."
+" ``{url}`` and ``{save_as}`` correspond respectively to the ``*_URL`` and"
+" ``*_SAVE_AS`` values of the corresponding page type (e.g. "
+"``ARTICLE_SAVE_AS``). If ``{save_as} == foo/bar.html``, then ``{name} == "
+"foo/bar`` and ``{extension} == .html``. ``{base_name}`` equals ``{name}``"
+" except that it strips trailing ``/index`` if present. ``{number}`` "
+"equals the page number."
+msgstr ""
+"在 ``page_url`` 和 ``page_save_as`` 中,你可以使用很多变量。对于不同的页面类型, ``{url}`` 和 "
+"``{save_as}`` 对应于其 ``*_URL`` 和 ``*_SAVE_AS`` 配置项的计算值(例如 "
+"``ARTICLE_SAVE_AS`` )。假设 ``{save_as} == foo/bar.html`` ,那么此时 ``{name} == "
+"foo/bar`` 、``{extension} == .html`` 。另外, ``{base_name}`` 和 ``{name}`` "
+"相同,只不过会截去末尾的 ``/index`` (如果有的话)。 ``{number}`` 则等于页码。(译者注: "
+"``minimum_page`` 意味到达该页面数后开始使用此条规则)"
+
+#: ../../settings.rst:1079 b3b8c76240bd4097b2ccd51e129fd949
+msgid ""
+"For example, if you want to leave the first page unchanged, but place "
+"subsequent pages at ``.../page/2/`` etc, you could set "
+"``PAGINATION_PATTERNS`` as follows::"
+msgstr ""
+"举个例子,如果你想要保持第一面保持不变,但后续页面都以 ``.../page/2/`` 的形式出现,你可以如此设置 "
+"``PAGINATION_PATTERNS`` :"
+
+#: ../../settings.rst:1089 d229ff3fdd86402c9c511d154856da26
+msgid ""
+"If you want a pattern to apply to the last page in the list, use ``-1`` "
+"as the ``minimum_page`` value::"
+msgstr "如果你想指定最后一面制定规则,将 ``minimum_page`` 的值设为 ``-1`` 即可:"
+
+#: ../../settings.rst:1095 8a2f277505ea4ec1bf03baf8e8558fe0
+msgid "Translations"
+msgstr "翻译"
+
+#: ../../settings.rst:1097 fd82b5daff4b4c019f3af94589fdf236
+msgid ""
+"Pelican offers a way to translate articles. See the :doc:`Content "
+"` section for more information."
+msgstr "Pelican为文章翻译提供了展示方法。详见 :doc:`创作内容 ` 。"
+
+#: ../../settings.rst:1102 0ed0fba765d44cb29c7a4561f1a7da11
+msgid "The default language to use."
+msgstr "指定默认语言。"
+
+#: ../../settings.rst:1106 b142b956828d4fa6bf5a6f41154a0bc8
+msgid ""
+"The metadata attribute(s) used to identify which articles are "
+"translations of one another. May be a string or a collection of strings. "
+"Set to ``None`` or ``False`` to disable the identification of "
+"translations."
+msgstr "指定用于标识不同翻译是同一篇文章的元数据。可以是一个或多个字符串。要禁用对文章翻译的识别,将此项设为 ``None`` 或 ``False`` 。"
+
+#: ../../settings.rst:1112 b7a889c0eda0476cb8926803274db471
+msgid ""
+"The metadata attribute(s) used to identify which pages are translations "
+"of one another. May be a string or a collection of strings. Set to "
+"``None`` or ``False`` to disable the identification of translations."
+msgstr "指定用于标识不同翻译是同一个页面的元数据。可以是一个或多个字符串。要禁用对页面翻译的识别,将此项设为 ``None`` 或 ``False`` 。"
+
+#: ../../settings.rst:1118 761a948ad532489ab91be66f6ff4afc3
+msgid "The location to save the Atom feed for translations. [3]_"
+msgstr "指定各翻译Atom订阅源的存储位置。 [3]_"
+
+#: ../../settings.rst:1122 3c51071a92a446179fa38606692a56d6
+msgid ""
+"Relative URL of the Atom feed for translations, including the ``{lang}`` "
+"placeholder. [3]_ If not set, ``TRANSLATION_FEED_ATOM`` is used both for "
+"save location and URL."
+msgstr ""
+"指定各翻译Atom feed的含有 ``{lang}`` 的相对URL。 [3]_ "
+"若未设置此项,``TRANSLATION_FEED_ATOM`` 会同时用于存储位置和URL。"
+
+#: ../../settings.rst:1128 12ef75b1e91b49a2884fc8508893a066
+msgid "Where to put the RSS feed for translations."
+msgstr "指定各翻译RSS订阅源的存储位置。"
+
+#: ../../settings.rst:1132 6b6d0ca12bbb4f26a2f91dea3ca2c6c7
+msgid ""
+"Relative URL of the RSS feed for translations, including the ``{lang}`` "
+"placeholder. [3]_ If not set, ``TRANSLATION_FEED_RSS`` is used both for "
+"save location and URL."
+msgstr ""
+"文章或页面不同翻译在RSS订阅源中的相对路径,其中含有 ``{lang}``。 [3]_ "
+"若未设置此项,``TRANSLATION_FEED_RSS`` 会同时用于存储位置和URL。"
+
+#: ../../settings.rst:1136 a653ebc90d404e1d88f473baa6d34bfa
+msgid "{lang} is the language code"
+msgstr "{lang} 为语言代码"
+
+#: ../../settings.rst:1140 417bf3d48cbb489daf8fab166ee7bda3
+msgid "Ordering content"
+msgstr "内容的排列顺序"
+
+#: ../../settings.rst:1144 0cf90a8d6a3f48879e6f835e7944ccf2
+msgid ""
+"Order archives by newest first by date. (False: orders by date with older"
+" articles first.)"
+msgstr "若设为True,日期较新的会排在前面;若设为False,则日期较旧的会排在前面。"
+
+#: ../../settings.rst:1149 69921fd37f9947948c4951ea539be84a
+msgid ""
+"Reverse the category order. (True: lists by reverse alphabetical order; "
+"default lists alphabetically.)"
+msgstr "若设为True,分类会按字典序逆序排列;若设为False,则按字典序顺序排列。"
+
+#: ../../settings.rst:1154 858fdbaaccf94d1392cf6c102da139a9
+msgid ""
+"Defines how the articles (``articles_page.object_list`` in the template) "
+"are sorted. Valid options are: metadata as a string (use ``reversed-`` "
+"prefix to reverse the sort order), special option ``'basename'`` which "
+"will use the basename of the file (without path), or a custom function to"
+" extract the sorting key from articles. Using a value of ``'date'`` will "
+"sort articles in chronological order, while the default value, "
+"``'reversed-date'``, will sort articles by date in reverse order (i.e., "
+"newest article comes first)."
+msgstr ""
+"定义文章(模板中的 ``articles_page.object_list`` "
+")的排序方式。有效选项包括:字符串形式的元数据(使用前缀reverse-来指定逆序)、特殊选项 ``'basename'`` "
+"(不带路径的文件名)、或是一个可以从文章中提取排序键的自定义函数。例如,将选项值设为 ``'date'`` ,文章就会以时间顺序排列文章。默认值为"
+" ``'reversed-date'`` ,即以日期逆序排列,即新文章在前、旧文章在后。"
+
+#: ../../settings.rst:1164 302ab57b0ae2473ebefff23151f4675f
+msgid ""
+"Defines how the pages (``pages`` variable in the template) are sorted. "
+"Options are same as ``ARTICLE_ORDER_BY``. The default value, "
+"``'basename'`` will sort pages by their basename."
+msgstr ""
+"定义页面(模板中的 ``pages`` 变量)的排序顺序。有效选项和 ``ARTICLE_ORDER_BY`` 中的相同。默认值为 "
+"``basename``。"
+
+#: ../../settings.rst:1172 8503a9717f4c4d37a15b95fe4881528f
+msgid "Themes"
+msgstr "主题"
+
+#: ../../settings.rst:1174 ee7c320a20664fd294235130ca68827e
+msgid ""
+"Creating Pelican themes is addressed in a dedicated section (see :ref"
+":`theming-pelican`). However, here are the settings that are related to "
+"themes."
+msgstr "创建Pelican主题在单独的一节中讲解(参见 :ref:`theming-pelican` )。此处讲解和主题有关的配置项。"
+
+#: ../../settings.rst:1180 a7abb7abd4fd4914a9b2de4e18f2166a
+msgid ""
+"Theme to use to produce the output. Can be a relative or absolute path to"
+" a theme folder, or the name of a default theme or a theme installed via "
+":doc:`pelican-themes` (see below)."
+msgstr ""
+"用于产生输出的主题。可以是到达要使用主题的文件夹的相对或绝对路径,或是主题的名称(默认主题或通过 :doc:`pelican-themes` "
+"安装的主题)。"
+
+#: ../../settings.rst:1186 c80860199b464fe9be8c59b8162cd446
+msgid ""
+"Destination directory in the output path where Pelican will place the "
+"files collected from `THEME_STATIC_PATHS`. Default is `theme`."
+msgstr ""
+"Pelican从 `THEME_STATIC_PATHS` 中发现主题要使用的静态文件,此设置项指定这些静态文件在输出路径中的目录。默认值为 "
+"`theme` 。"
+
+#: ../../settings.rst:1191 7dbeb5f932f345c9b7c3546b7cfb788f
+msgid ""
+"Static theme paths you want to copy. Default value is `static`, but if "
+"your theme has other static paths, you can put them here. If files or "
+"directories with the same names are included in the paths defined in this"
+" settings, they will be progressively overwritten."
+msgstr ""
+"要复制的静态主题路径。默认值为 `static` "
+",但如果你的主题有其他静态路径,也可以将其放在此处。此项设置中若包含了相同名称的文件或目录,前面的会被后面的覆盖。"
+
+#: ../../settings.rst:1198 fe7833a44b7547a889fb97b77b219186
+msgid ""
+"A list of paths you want Jinja2 to search for templates before searching "
+"the theme's ``templates/`` directory. Allows for overriding individual "
+"theme template files without having to fork an existing theme. Jinja2 "
+"searches in the following order: files in ``THEME_TEMPLATES_OVERRIDES`` "
+"first, then the theme's ``templates/``."
+msgstr ""
+"在搜索主题的 ``templates/`` "
+"目录前,Jinja2会先搜索此设置项中的路径。可以使用此设置项覆盖主题中的某些模板文件,以尽量避免修改现有主题。"
+
+#: ../../settings.rst:1204 fb8d33e45bd7411eb4c709bc8735725f
+#, python-format
+msgid ""
+"You can also extend templates from the theme using the ``{% extends %}`` "
+"directive utilizing the ``!theme`` prefix as shown in the following "
+"example:"
+msgstr "利用 ``{% extends %}`` 指令中的 ``!theme`` 前缀也可以用于从主题扩展模板,如下例所示:"
+
+#: ../../settings.rst:1213 bad5f78cf14f48cfa4e3031fc66e945a
+msgid "Specify the CSS file you want to load."
+msgstr "指定需要加载的CSS文件。"
+
+#: ../../settings.rst:1215 744422adebf048efb9576eb3d6f01b4f
+msgid ""
+"By default, two themes are available. You can specify them using the "
+"``THEME`` setting or by passing the ``-t`` option to the ``pelican`` "
+"command:"
+msgstr "默认情况下,有两个主题可供选择。可以使用 ``THEME`` 选项指定,或是在 ``pelican`` 命令中使用 ``-t`` 选项的参数传入。"
+
+#: ../../settings.rst:1218 bad7ba14225c4a47922ce9440f0bfb11
+msgid "notmyidea"
+msgstr "notmyidea(默认值)"
+
+#: ../../settings.rst:1219 16954ec8b6224cd7902c5af01586f5cb
+msgid "simple (a synonym for \"plain text\" :)"
+msgstr "simple(即“plain text”)"
+
+#: ../../settings.rst:1221 7d839f8fe8ea454abb64906c4cf38932
+msgid ""
+"There are a number of other themes available at "
+"https://github.com/getpelican/pelican-themes. Pelican comes with :doc"
+":`pelican-themes`, a small script for managing themes."
+msgstr ""
+"还有很多主题可以在 https://github.com/getpelican/pelican-themes 上下载。Pelican使用一个称为 "
+":doc:`pelican-themes` 的小脚本来管理主题。"
+
+#: ../../settings.rst:1225 d512f8161e89412693a9acb00948e348
+msgid ""
+"You can define your own theme, either by starting from scratch or by "
+"duplicating and modifying a pre-existing theme. Here is :doc:`a guide on "
+"how to create your theme `."
+msgstr "你还可以创建自己的主题,可以从头开始,也可以在已有主题的基础上修改。请参看 :doc:`主题 ` 文档。"
+
+#: ../../settings.rst:1229 696c62600fb4479bbbbc6a010024d2aa
+msgid "Following are example ways to specify your preferred theme::"
+msgstr "下面是几个指定某个主题的例子:"
+
+#: ../../settings.rst:1240 e70559ce885e4db0aa17a71a9a2ed757
+msgid ""
+"The built-in ``simple`` theme can be customized using the following "
+"settings."
+msgstr "内置的 ``simple`` 主题可以使用以下设置项进行自定义。"
+
+#: ../../settings.rst:1244 67a316d5c57045448387c17445e71a53
+msgid "The URL of the stylesheet to use."
+msgstr "要使用的样式表的URL。"
+
+#: ../../settings.rst:1246 61fc5d9b1f0c4b6586fd458660e384ff
+msgid ""
+"The built-in ``notmyidea`` theme can make good use of the following "
+"settings. Feel free to use them in your themes as well."
+msgstr "下面的一下选项可以很好地作用于内置的 ``notmyidea`` 主题。当然在其他主题中你也可以尽情尝试这些选项。"
+
+#: ../../settings.rst:1251 fdd6425dea494c098212b971ed30bb71
+msgid "A subtitle to appear in the header."
+msgstr "页面顶部要显示的副标题。"
+
+#: ../../settings.rst:1255 706528c7601a4352a40399b6a7b8b8dd
+msgid ""
+"Pelican can handle Disqus comments. Specify the Disqus sitename "
+"identifier here."
+msgstr "可以在Pelican中使用Disqus的评论系统,此设置项用于设置Disqus的站点标识符。"
+
+#: ../../settings.rst:1260 c0ff07ee87814a60b798b0b22b562af0
+msgid ""
+"Your GitHub URL (if you have one). It will then use this information to "
+"create a GitHub ribbon."
+msgstr "指定你的GitHub URL(如果有的话),此信息将被用于创建GitHub功能区。"
+
+#: ../../settings.rst:1265 751716f49245400b99fdbb95052f8cb4
+msgid ""
+"Put any desired analytics scripts in this setting in ``publishconf.py``. "
+"Example:"
+msgstr "在 ``publishconf.py`` 中设置此项,用于指定想要使用的统计分析脚本。如下例:"
+
+#: ../../settings.rst:1279 e65031f7629d4b06b837b05b80b68141
+msgid ""
+"A list of tuples (Title, URL) for additional menu items to appear at the "
+"beginning of the main menu."
+msgstr "元组 (标题, URL) 的列表,用于指定额外的菜单项,会添加在菜单栏的开头。"
+
+#: ../../settings.rst:1284 13839251877b49bb9962c0bc7b75f951
+msgid "A list of tuples (Title, URL) for links to appear on the header."
+msgstr "元组 (标题, URL) 的列表,用于指定要展示在网页开头的链接。"
+
+#: ../../settings.rst:1288 3a22924a9cb242029138754da6257800
+msgid "A list of tuples (Title, URL) to appear in the \"social\" section."
+msgstr "元组 (标题, URL) 的列表,用于指定要展示在“social”部分的内容。"
+
+#: ../../settings.rst:1292 4e64ba4558af483ea5234a40b6a7f667
+msgid ""
+"Allows for adding a button to articles to encourage others to tweet about"
+" them. Add your Twitter username if you want this button to appear."
+msgstr "允许在文章中添加按钮,以鼓励其他人发布有关它们的推文。如果希望显示此按钮,在此项中设置你的Twitter用户名。"
+
+#: ../../settings.rst:1297 1948a7f1556942869467e12269a83c97
+msgid ""
+"Allows override of the name of the links widget. If not specified, "
+"defaults to \"links\"."
+msgstr "指定用于覆盖“links”部分的名称。默认值为“links”。"
+
+#: ../../settings.rst:1302 4fcc458a089d46ec80586edae17cd901
+msgid ""
+"Allows override of the name of the \"social\" widget. If not specified, "
+"defaults to \"social\"."
+msgstr "指定用于覆盖“social”部分的名称。默认值为“social”。"
+
+#: ../../settings.rst:1305 481872501e9f4df687b70830929f429f
+msgid ""
+"In addition, you can use the \"wide\" version of the ``notmyidea`` theme "
+"by adding the following to your configuration::"
+msgstr "另外,你可以使用 ``notmyidea`` 主题的“宽屏”版本,在配置文件中添加下面这行配置即可:"
+
+#: ../../settings.rst:1312 add39f626ea24dd6885a117bdbef1c2b
+msgid "Logging"
+msgstr "日志"
+
+#: ../../settings.rst:1314 16c2fccd07c44079989173c2b101439f
+msgid ""
+"Sometimes, a long list of warnings may appear during site generation. "
+"Finding the **meaningful** error message in the middle of tons of "
+"annoying log output can be quite tricky. In order to filter out redundant"
+" log messages, Pelican comes with the ``LOG_FILTER`` setting."
+msgstr ""
+"在站点生成过程中有时可能会出现一堆警告信息。在这一大堆日志输出中寻找 **有意义** "
+"的错误消息是非常棘手的。为了过滤掉多余的日志消息,可以在Pelican中指定 ``LOG_FILTER`` 设置。"
+
+#: ../../settings.rst:1319 0a8d1eb4cad64db1bdccc37e40c0d5b9
+msgid ""
+"``LOG_FILTER`` should be a list of tuples ``(level, msg)``, each of them "
+"being composed of the logging level (up to ``warning``) and the message "
+"to be ignored. Simply populate the list with the log messages you want to"
+" hide, and they will be filtered out."
+msgstr ""
+"``LOG_FILTER`` 是元组 ``(level, msg)`` ,level指定日志记录等级(最高为 ``warning`` "
+"),msg指定要忽略的消息。将想要隐藏的日志消息添加到此列表中就可以将他们过滤掉。"
+
+#: ../../settings.rst:1324 ../../settings.rst:1332
+#: a060e3f3d20b4f5ca0891c81e1e6bf44
+msgid "For example::"
+msgstr "例如:"
+
+#: ../../settings.rst:1329 66bf87b59c0547d6992c494296f54cba
+msgid ""
+"It is possible to filter out messages by a template. Check out source "
+"code to obtain a template."
+msgstr "用模板字符串指定要过滤的消息也是可以的。具体的消息种类请查看源码。"
+
+#: ../../settings.rst:1339 77c817d503564c58b81e694cd2f2c357
+msgid ""
+"Silencing messages by templates is a dangerous feature. It is possible to"
+" unintentionally filter out multiple message types with the same template"
+" (including messages from future Pelican versions). Proceed with caution."
+msgstr "通过模板过滤忽略消息是一个危险的功能。 使用同一模板可能会无意中过滤掉多种消息类型(包括来自新版本Pelican的消息),请谨慎行事。"
+
+#: ../../settings.rst:1345 2ca9fb8cc8854442b52381580df2423e
+msgid "This option does nothing if ``--debug`` is passed."
+msgstr "当使用了 ``--debug`` 参数,此项设置就不会起作用。"
+
+#: ../../settings.rst:1351 a915c4d447a44d9d8f1df8aeb978a590
+msgid "Reading only modified content"
+msgstr "只读取修改过的内容"
+
+#: ../../settings.rst:1353 7c899d3702eb4c9389b29caa1dd199bf
+msgid ""
+"To speed up the build process, Pelican can optionally read only articles "
+"and pages with modified content."
+msgstr "为了加速网站构建过程,Pelican能够只读取修改过内容的文章和页面。"
+
+#: ../../settings.rst:1356 22170a8c737540d6b2826de10d97f57e
+msgid "When Pelican is about to read some content source file:"
+msgstr "当Pelican准备读取内容源文件时,会执行下面的规则:"
+
+#: ../../settings.rst:1358 c746f9e5624441c4a53d81f9049910d8
+msgid ""
+"The hash or modification time information for the file from a previous "
+"build are loaded from a cache file if ``LOAD_CONTENT_CACHE`` is ``True``."
+" These files are stored in the ``CACHE_PATH`` directory. If the file has"
+" no record in the cache file, it is read as usual."
+msgstr ""
+"若 ``LOAD_CONTENT_CACHE`` 为 ``True`` "
+",则从缓存文件中加载上一次构建时文件的哈希值或修改时间。这些缓存的文件存储在 ``CACHE_PATH`` "
+"所指定的目录中。若文件是新的,在缓存文件中没有记录,则照常读取。"
+
+#: ../../settings.rst:1362 20764c61c87044a6a7cfaca089dbe088
+msgid "The file is checked according to ``CHECK_MODIFIED_METHOD``:"
+msgstr "文件会以 ``CHECK_MODIFIED_METHOD`` 设置的方式检查:"
+
+#: ../../settings.rst:1368 f31c72607b3c4c6e99d97c7db70ffdd6
+msgid ""
+"If set to anything else or the necessary information about the file "
+"cannot be found in the cache file, the content is read as usual."
+msgstr "如果设置为其他任何值或在缓存文件中无法找到有关该文件的必要信息,则将照常读取内容。"
+
+#: ../../settings.rst:1371 32c11190a05847fc94ef489e2cd75ebc
+msgid ""
+"If the file is considered unchanged, the content data saved in a previous"
+" build corresponding to the file is loaded from the cache, and the file "
+"is not read."
+msgstr "如果Pelican认为文件没有更改过,会直接从上一次构建的对应文件中加载内容,源文件就不会被读取。"
+
+#: ../../settings.rst:1374 8a6a10580d4646c08562a415ab80b032
+msgid ""
+"If the file is considered changed, the file is read and the new "
+"modification information and the content data are saved to the cache if "
+"``CACHE_CONTENT`` is ``True``."
+msgstr ""
+"若Pelican认为文件更改过了,则会读取源文件;若 ``CACHE_CONTENT`` 设为了 ``True`` "
+",Pelican还会将修改后的信息以及内容数据存入缓存。"
+
+#: ../../settings.rst:1378 4d2198d1f1a04c0ab92bd5a2bfe2f3bd
+msgid ""
+"If ``CONTENT_CACHING_LAYER`` is set to ``'reader'`` (the default), the "
+"raw content and metadata returned by a reader are cached. If this setting"
+" is instead set to ``'generator'``, the processed content object is "
+"cached. Caching the processed content object may conflict with plugins "
+"(as some reading related signals may be skipped) and the "
+"``WITH_FUTURE_DATES`` functionality (as the ``draft`` status of the "
+"cached content objects would not change automatically over time)."
+msgstr ""
+"若 ``CONTENT_CACHING_LAYER`` 设为了 ``'reader'`` (默认值),则缓存reader返回的原始内容和元数据;若"
+" ``CONTENT_CACHING_LAYER`` 设为了 ``'generator'`` "
+",则缓存处理过后的内容对象。缓存已处理的内容对象可能会和插件(因为可能会跳过一些与读取相关的信号)与 ``WITH_FUTURE_DATES`` "
+"的功能(因为已处理内容对象的 ``draft`` 状态不会改变)冲突。"
+
+#: ../../settings.rst:1386 75139bf4fb6f40649b4691f4158d1eee
+msgid ""
+"Checking modification times is faster than comparing file hashes, but it "
+"is not as reliable because ``mtime`` information can be lost, e.g., when "
+"copying content source files using the ``cp`` or ``rsync`` commands "
+"without the ``mtime`` preservation mode (which for ``rsync`` can be "
+"invoked by passing the ``--archive`` flag)."
+msgstr ""
+"检查文件修改时间比计算文件哈希更快,但事实上却不太可靠,因为 ``mtime`` 信息有丢失的可能。例如,使用 ``cp`` 或 "
+"``rsync`` 命令时没有开启 ``mtime`` 保留模式。(rsync可以通过指定 ``--archive`` 标志启用 "
+"``mtime`` 保留模式)"
+
+#: ../../settings.rst:1392 f556d8c0bd75495ca85a41e310637101
+msgid ""
+"The cache files are Python pickles, so they may not be readable by "
+"different versions of Python as the pickle format often changes. If such "
+"an error is encountered, it is caught and the cache file is rebuilt "
+"automatically in the new format. The cache files will also be rebuilt "
+"after the ``GZIP_CACHE`` setting has been changed."
+msgstr ""
+"缓存文件使用的是Python "
+"pickles,因此不同版本的Python由于pickle文件格式变化可能无法读取缓存。如果遇到此类错误,会自动以新格式重新构建缓存。另外,当 "
+"``GZIP_CACHE`` 设置发生变化后,缓存也会自动重建。"
+
+#: ../../settings.rst:1398 2b6a584c560d467ba34a744bb37c0006
+msgid ""
+"The ``--ignore-cache`` command-line option is useful when the whole cache"
+" needs to be regenerated, such as when making modifications to the "
+"settings file that will affect the cached content, or just for debugging "
+"purposes. When Pelican runs in autoreload mode, modification of the "
+"settings file will make it ignore the cache automatically if "
+"``AUTORELOAD_IGNORE_CACHE`` is ``True``."
+msgstr ""
+"当需要重新生成整个缓存时,可以使用 ``--ignore-cache`` "
+"命令行选项,例如当需要修改会影响缓存内容的设置项时,或是调试时,都可以使用 ``--ignore-cache`` 。若 "
+"``AUTORELOAD_IGNORE_CACHE`` 设为了 ``True`` ,修改设置文件时会自动忽略缓存。"
+
+#: ../../settings.rst:1404 a38225b961234c2e96f6d0f2545ed455
+msgid ""
+"Note that even when using cached content, all output is always written, "
+"so the modification times of the generated ``*.html`` files will always "
+"change. Therefore, ``rsync``-based uploading may benefit from the "
+"``--checksum`` option."
+msgstr ""
+"需要注意的是,即使使用了缓存的内容,最终的输出文件也始终会进行重新写入,因此生成的 ``*.html`` 文件的修改时间始终会变化。所以,基于 "
+"``rsync`` 进行上传时,可以考虑使用 ``--checksum`` 选项。"
+
+#: ../../settings.rst:1411 2aa4b6fbbab24465ab36a606cecf299c
+msgid "Example settings"
+msgstr "配置示例"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/sphinx.po b/docs/locale/zh_CN/LC_MESSAGES/sphinx.po
new file mode 100644
index 00000000..860cbcb2
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/sphinx.po
@@ -0,0 +1,60 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-24 19:06+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../_templates/page.html:68 697aead398874e06aa15cfd74d134745
+msgid "Back to top"
+msgstr "返回顶部"
+
+#: ../../_templates/page.html:101 f91a64e54aae49c2bd09a944ea693193
+msgid "Next"
+msgstr "下一节"
+
+#: ../../_templates/page.html:113 6c3ad069077b4e2cb6e1f77cc2962881
+msgid "Previous"
+msgstr "前一节"
+
+#: ../../_templates/page.html:116 e83e03d0b50c4065a9f87db25a23b3ee
+msgid "Home"
+msgstr "首页"
+
+#: ../../_templates/page.html:129 1d0fdb4c0b4e420283101ba5c21ac985
+#, python-format
+msgid "Copyright © %(copyright)s"
+msgstr "Copyright © %(copyright)s"
+
+#: ../../_templates/page.html:133 0a35c662e6574da48f7ac5c6b2c82874
+#, python-format
+msgid ""
+"Copyright © %(copyright)s, Justin Mayer, Alexis Metaireau, and "
+"contributors"
+msgstr ""
+"Copyright © %(copyright)s, Justin Mayer, Alexis Metaireau, and "
+"contributors"
+
+#: ../../_templates/page.html:141 07b89372db484251bfcd3b54e0845bf0
+#, python-format
+msgid "Last updated on %(last_updated)s"
+msgstr "最后更新于 %(last_updated)s"
+
+#: ../../_templates/page.html:187 2eb9f1b479a7405290a91d8e1962f265
+msgid "On this page"
+msgstr "本页目录"
diff --git a/docs/locale/zh_CN/LC_MESSAGES/themes.po b/docs/locale/zh_CN/LC_MESSAGES/themes.po
new file mode 100644
index 00000000..5f626265
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/themes.po
@@ -0,0 +1,1269 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-25 20:36+0800\n"
+"PO-Revision-Date: 2024-06-26 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../themes.rst:4 89902fe106274689a45bfad9447f4485
+msgid "Themes"
+msgstr "主题"
+
+#: ../../themes.rst:6 877321a191544e6db8b1fe257b7bfc82
+msgid ""
+"There is a community-managed repository of `Pelican Themes`_ for people "
+"to share and use."
+msgstr ""
+"有一个由社区管理的主题仓库 `Pelican Themes`_ 供大家使用。"
+
+#: ../../themes.rst:9 6f0fdcf7ea28413482621e993a00aba2
+msgid ""
+"Please note that while we do our best to review and merge theme "
+"contributions, they are submitted by the Pelican community and thus may "
+"have varying levels of support and interoperability."
+msgstr ""
+"请注意,虽然我们已经尽全力审查与合并主题,但是由于他们是由社区提交的,因此"
+"支持性和互操作性各有不同。"
+
+#: ../../themes.rst:14 f4083056816746ad8779108e8605f782
+msgid "Creating Themes"
+msgstr "创建主题"
+
+#: ../../themes.rst:16 11544ff05900447c9d89b7e4b762b456
+msgid ""
+"To generate its HTML output, Pelican uses the `Jinja "
+"`_ templating engine due to its "
+"flexibility and straightforward syntax. If you want to create your own "
+"theme, feel free to take inspiration from the `\"simple\" theme "
+"`_."
+msgstr ""
+"Pelican使用 `Jinja `_ 来生成HTML。"
+"如果你想要创建你自己的主题,请从 `\"simple\" 主题 "
+"`_ "
+"中找寻灵感。"
+
+#: ../../themes.rst:22 646df766f1a64f6e89ba22466a9a57ee
+msgid ""
+"To generate your site using a theme you have created (or downloaded "
+"manually and then modified), you can specify that theme via the ``-t`` "
+"flag::"
+msgstr ""
+"要使用你自己创建的主题生成站点,你可以通过命令行中的 ``-t`` 参数指定主题:"
+
+#: ../../themes.rst:27 f3b0f229f56444d0b09f27dcc5076398
+msgid ""
+"If you'd rather not specify the theme on every invocation, you can define"
+" ``THEME`` in your settings to point to the location of your preferred "
+"theme."
+msgstr ""
+"如果你不希望每次都通过命令行手动指定主题,你可以在配置文件中定义 ``THEME`` "
+"来指定你希望使用的主题的位置。"
+
+#: ../../themes.rst:32 b8028cb48f844e16b49bd30e6f7c7ec5
+msgid "Structure"
+msgstr "结构"
+
+#: ../../themes.rst:34 a3fcbbe24e4c4448b09db74e7140dd52
+msgid "To make your own theme, you must follow the following structure::"
+msgstr "你需要遵循下面的结构来制作你自己的主题:"
+
+#: ../../themes.rst:52 153830a0dc1c47358f1fd67c11174676
+msgid ""
+"`static` contains all the static assets, which will be copied to the "
+"output `theme` folder. The above filesystem layout includes CSS and image"
+" folders, but those are just examples. Put what you need here."
+msgstr ""
+"`static` 文件夹包含了所有静态资源,会被复制输出到 `theme` 文件夹中。上面的文件夹"
+"布局结构包括了CSS和image文件夹,但是这只是举个例子。你可以根据需求安排文件。"
+
+#: ../../themes.rst:56 e923579cd7b74cdc94f43d4da4e47b2e
+msgid ""
+"`templates` contains all the templates that will be used to generate the "
+"content. The template files listed above are mandatory; you can add your "
+"own templates if it helps you keep things organized while creating your "
+"theme."
+msgstr ""
+"`templates` 文件夹包含了需要用到的所有模板文件,这些模板文件会用于生成网站内容。"
+"上面列出的模板文件都是必须有的。当然,你可以添加一些其他的模板来帮助组织主题文件。"
+
+#: ../../themes.rst:64 354197c97b424a53b682d31d2432bbd7
+msgid "Templates and Variables"
+msgstr "模板和变量"
+
+#: ../../themes.rst:66 263ff11382b1433082f35b605ed76f4b
+msgid ""
+"The idea is to use a simple syntax that you can embed into your HTML "
+"pages. This document describes which templates should exist in a theme, "
+"and which variables will be passed to each template at generation time."
+msgstr ""
+"你可以将一些简单的语法嵌入到HTML文件中。以下文档描述了哪些模板需要存在于主题中,"
+"以及有哪些变量可以在模板中使用。"
+
+#: ../../themes.rst:70 b511ed5df3fc4f75a8e9ca6e874b6cf7
+msgid ""
+"All templates will receive the variables defined in your settings file, "
+"as long as they are in all-caps. You can access them directly."
+msgstr ""
+"所有模板都能接收到配置文件中定义的变量,变量名都是全大写的,可以直接使用。"
+
+#: ../../themes.rst:77 903d9890350a4b08a3c5e11bdc202d10
+msgid "Common Variables"
+msgstr "通用变量"
+
+#: ../../themes.rst:79 fa18fc2c334d4b51ae7545d24a8b5df5
+msgid "All of these settings will be available to all templates."
+msgstr "下列变量在所有模板中均可使用。"
+
+#: ../../themes.rst:82 ../../themes.rst:170 ../../themes.rst:199
+#: ../../themes.rst:233 ../../themes.rst:266 ../../themes.rst:306
+#: ../../themes.rst:322 ../../themes.rst:355 1a4a93014c47420d8957a7f2209d6525
+#: 2d1889e9a23a4cb298d38366289f381d 63553de1af084662a41fded0a700913d
+#: 87ec83ae24564eaf831ada4f4aab01a3 8907d23ec9f94b5b83a9bdd717fc95bd
+#: 951f8b457243424da836ecf85c5db0e1 a3866a27423c4782a6d47b28d41e1144
+#: eee781bef37d4e94a9796ff50dd63447
+msgid "Variable"
+msgstr "变量名"
+
+#: ../../themes.rst:82 ../../themes.rst:170 ../../themes.rst:199
+#: ../../themes.rst:233 ../../themes.rst:266 ../../themes.rst:306
+#: ../../themes.rst:322 ../../themes.rst:355 ../../themes.rst:446
+#: ../../themes.rst:490 ../../themes.rst:509 17384d55be144a6ab765864d5833f96f
+#: 2e69f59326a04747b7655b61a713bcf5 46ecfcac4e0b48879a665f5ded2abc4c
+#: 4b4d47cfd511455db6eb2793e60907b6 6b9bab6f2603419da0032456f90e326a
+#: 9cadd069ae2b471eaaeeac1281b7f88d af7a426781734d61a2f1c95aff008adc
+#: c1274b2e4b5442d7b9774ffacdd22c1a f53c09af9fd642f7a26552ada70160d8
+#: f9ffc9bb411340199e68bb28e1c38e97 ff0cc823d5f44c71be4d9dfb09198ae5
+msgid "Description"
+msgstr "描述"
+
+#: ../../themes.rst:84 92684afe53b74e5eacca15acf5567c1c
+msgid "output_file"
+msgstr "output_file"
+
+#: ../../themes.rst:84 9534d42aed3a4f5bbcefb8f9aebefc9e
+msgid ""
+"The name of the file currently being generated. For instance, when "
+"Pelican is rendering the home page, output_file will be \"index.html\"."
+msgstr ""
+"当前正在生成的文件名。例如在Pelican渲染主页时,此变量的值就是“index.html”。"
+
+#: ../../themes.rst:87 ../../themes.rst:202 ../../themes.rst:236
+#: ../../themes.rst:325 ../../themes.rst:406 5e810b19b7934988905a23189aa25584
+#: 7ce75b9ff72a41368aa4d85147b3ee01 b304eca8c6ab4a97b9f9816e48e785a3
+#: b4b801b67a5f4a038664df8273752437 f6d5de62ec124133abd3e71d052076c9
+msgid "articles"
+msgstr "articles"
+
+#: ../../themes.rst:87 a37338288479498dabc0d35a3499ae2a
+msgid ""
+"The list of articles, ordered descending by date. All the elements are "
+"`Article` objects, so you can access their attributes (e.g. title, "
+"summary, author etc.). Sometimes this is shadowed (for instance, in the "
+"tags page). You will then find info about it in the `all_articles` "
+"variable."
+msgstr ""
+"文章列表,以日期降序排列。所有元素都是 `Article` 对象,因此你可以访问 `Article` "
+"对象的属性(例如title、summary、author等)。有时候此变量是隐藏的(例如在标签页面中)。"
+"但仍可以在 `all_articles` 变量中找到相关信息。"
+
+#: ../../themes.rst:93 ../../themes.rst:203 ../../themes.rst:237
+#: ../../themes.rst:326 ../../themes.rst:408 100c5d8c8602411da08bfcde279249f2
+#: 24ff711ecb9e4308b52d404b822244f3 389e8343632d48048b4ced0128d20011
+#: 3d9a59ea4c7a428998e0bb4df84c6576 b0fe593f0e774b7a9b33ff8e44c8284a
+msgid "dates"
+msgstr "dates"
+
+#: ../../themes.rst:93 957d856345744280bb8cde05d15b934c
+msgid "The same list of articles, but ordered by date, ascending."
+msgstr "和articles相同的文章列表,但是以日期升序排列"
+
+#: ../../themes.rst:95 850f75175d0f44c9987b95b244e0e085
+msgid "hidden_articles"
+msgstr "hidden_articles"
+
+#: ../../themes.rst:95 2853b0eb27e241c78c5ad83d8d502905
+msgid "The list of hidden articles"
+msgstr "处于隐藏状态的文章的列表"
+
+#: ../../themes.rst:96 68baf2e00aeb4fbbb9b18c562f5215de
+msgid "drafts"
+msgstr "drafts"
+
+#: ../../themes.rst:96 3eefce5813424f4b8a5edb283ec34699
+msgid "The list of draft articles"
+msgstr "处于草稿状态的文章的列表"
+
+#: ../../themes.rst:97 2bde499d530048a8ba3e5fb72a4a1840
+msgid "period_archives"
+msgstr "period_archives"
+
+#: ../../themes.rst:97 afad8caed5294d4bae4922b2674806ff
+msgid ""
+"A dictionary containing elements related to time-period archives (if "
+"enabled). See the section :ref:`Listing and Linking to Period Archives "
+"` for details."
+msgstr ""
+"一个字典,包含与时间段存档相关的元素(若启用了时间段存档)。详见 "
+":ref:`时间段存档的列表和链接 `"
+
+#: ../../themes.rst:101 ../../themes.rst:450 0b796b141cc24e34b57bc554273720c1
+#: d5bf3dd243d04c55ace1738de4d5b81b
+msgid "authors"
+msgstr "authors"
+
+#: ../../themes.rst:101 10010e1b527e4eedb7477d52bbf0ed94
+msgid ""
+"A list of (author, articles) tuples, containing all the authors and "
+"corresponding articles (values)"
+msgstr ""
+"元组(author, articles)的列表,包含所有作者及对应文章。"
+
+#: ../../themes.rst:103 7bb90c8b99344911b68de2dc8ba1a9d7
+msgid "categories"
+msgstr "categories"
+
+#: ../../themes.rst:103 becaee92fa434a47bb2ffa4ba6d3d863
+msgid ""
+"A list of (category, articles) tuples, containing all the categories and "
+"corresponding articles (values)"
+msgstr ""
+"元组(category, articles)的列表,包含所有分类及对应文章"
+
+#: ../../themes.rst:105 ../../themes.rst:470 ../../themes.rst:529
+#: 9d21fa3040b14b91a47dff071caae024 b8597a5c585e43a0bb544bfe8cf9bd26
+#: d692f555b4ea461ca4d8c0c65a67f21a
+msgid "tags"
+msgstr "tags"
+
+#: ../../themes.rst:105 0c0424ec68a74f578e271d0b1fe44b28
+msgid ""
+"A list of (tag, articles) tuples, containing all the tags and "
+"corresponding articles (values)"
+msgstr ""
+"元组(tag, articles)的列表,包含所有标签及对应文章"
+
+#: ../../themes.rst:107 196d2ef3131b4ab2b7e90a43d8c17dcd
+msgid "pages"
+msgstr "pages"
+
+#: ../../themes.rst:107 abb2b6303bb44b3e9335fcc9bfa2a704
+msgid "The list of pages"
+msgstr "页面的列表"
+
+#: ../../themes.rst:108 14a71679646448d59f6ccc2c63c2cc8b
+msgid "hidden_pages"
+msgstr "hidden_pages"
+
+#: ../../themes.rst:108 dfc32fdbe91240a78c15ff048e2f58ce
+msgid "The list of hidden pages"
+msgstr "处于隐藏状态的页面的列表"
+
+#: ../../themes.rst:109 78a644f88301408e977449a4fc0ffe12
+msgid "draft_pages"
+msgstr "draft_pages"
+
+#: ../../themes.rst:109 7418727938f343da8cb0071239f67d71
+msgid "The list of draft pages"
+msgstr "处于草稿状态的页面的列表"
+
+#: ../../themes.rst:114 04e0bd5e7d504ff8975c8492ce8c250a
+msgid "Sorting"
+msgstr "排序"
+
+#: ../../themes.rst:116 edae254af6974908bbeb7125dca0c708
+msgid ""
+"URL wrappers (currently categories, tags, and authors), have comparison "
+"methods that allow them to be easily sorted by name::"
+msgstr ""
+"URL包装器(分类、标签、作者),都拥有比较方法,使其易于按名称排序:"
+
+#: ../../themes.rst:121 878bb8a3a3064552b7608444cb419856
+msgid ""
+"If you want to sort based on different criteria, `Jinja's sort command`__"
+" has a number of options."
+msgstr ""
+"如果你想要以不同条件进行排序,可以使用 `Jinja的排序命令`__ ,其中有丰富的选项。"
+
+#: ../../themes.rst:128 3f3c857d79ed447f9dd3f5ce91082747
+msgid "Date Formatting"
+msgstr "日期格式"
+
+#: ../../themes.rst:130 37d3f94188aa435297071a869bfdca96
+msgid ""
+"Pelican formats the date according to your settings and locale "
+"(``DATE_FORMATS``/``DEFAULT_DATE_FORMAT``) and provides a ``locale_date``"
+" attribute. On the other hand, the ``date`` attribute will be a "
+"`datetime`_ object. If you need custom formatting for a date different "
+"than your settings, use the Jinja filter ``strftime`` that comes with "
+"Pelican. Usage is same as Python `strftime`_ format, but the filter will "
+"do the right thing and format your date according to the locale given in "
+"your settings::"
+msgstr ""
+"Pelican会根据设置和地区( ``DATE_FORMATS``/``DEFAULT_DATE_FORMAT`` )对日期"
+"进行格式化,同时还会提供一个 ``locale_date`` 属性。 ``date`` 属性以 `datetime`_ "
+"类表示。如果你需要使用与设置中不同的自定义日期格式,使用Jinja中的 ``strftime`` "
+"过滤器即可。用法Python中的 `strftime`_ 相同,但是过滤器会根据设置中给出的地区对"
+"日期进行格式化:"
+
+#: ../../themes.rst:144 cc5bc390c54b4c4f96641b2d8efe2169
+msgid "Checking Loaded Plugins"
+msgstr "检测已加载的插件"
+
+#: ../../themes.rst:146 2805eea94378479eafe1f9e214875f44
+msgid ""
+"Pelican provides a ``plugin_enabled`` Jinja test for checking if a "
+"certain plugin is enabled. This test accepts a plugin name as a string "
+"and will return a Boolean. Namespace plugins can be specified by full "
+"name (``pelican.plugins.plugin_name``) or short name (``plugin_name``). "
+"The following example uses the ``webassets`` plugin to minify CSS if the "
+"plugin is enabled and otherwise falls back to regular CSS::"
+msgstr ""
+"Pelican 提供了一个名为 ``plugin_enabled`` 的Jinja test,可用于检测某个插件是否启用。"
+"此test以字符串形式接受一个插件名称,并且返回一个布尔值。命名空间插件可以通过全名"
+"( ``pelican.plugins.plugin_name`` )或者短名称( ``plugin_name`` )指定。"
+"下面的例子中通过 ``webassets`` 插件来减小CSS的体积,但若此插件未启用,则回滚回普通的CSS:"
+
+#: ../../themes.rst:162 f31869529aef47a28224e3da3bc0c702
+msgid "index.html"
+msgstr "index.html"
+
+#: ../../themes.rst:164 d412aecaa8e34b2ca56032be8711b258
+msgid "This is the home page or index of your blog, generated at ``index.html``."
+msgstr "站点的主页,可以理解为推文的索引页,生成为 ``index.html`` 。"
+
+#: ../../themes.rst:166 396a268629374d1aaef9857ccff9ee53
+msgid ""
+"If pagination is active, subsequent pages will reside in "
+"``index{number}.html``."
+msgstr ""
+"如果开启了分页功能,后续的页面会以 ``index{number}.html`` 的形式生成。"
+
+#: ../../themes.rst:172 ../../themes.rst:205 ../../themes.rst:239
+#: ../../themes.rst:328 08f6e73beb544181b9b2627ad68dbbfe
+#: 244d220cd8684bb68489bf61227f87b5 34b8185111f54d8fbffa9ac5a87302a8
+#: d7bcb30486284e9dac239a40d4b9f229
+msgid "articles_paginator"
+msgstr "articles_paginator"
+
+#: ../../themes.rst:172 ../../themes.rst:205 ../../themes.rst:239
+#: ../../themes.rst:328 3fa810e9ae1d4dc1839754210e5d2570
+#: 9554b801f6df475caedff0345c5dfb93 bbc15c5dfe934bcd9e5f258f2008af11
+#: e5952c856b7d4670a93a99863ef94c49
+msgid "A paginator object for the list of articles"
+msgstr "一个分页器对象,其中存放着文章列表"
+
+#: ../../themes.rst:173 ../../themes.rst:206 ../../themes.rst:240
+#: ../../themes.rst:329 2362ac4e51264ba8b1a38272414c026c
+#: 755bbbd447fe420eb124c1dcbfecd767 7eaa5ec86823488fa38009e3a5bf1756
+#: 82eef974e6c2428eb29528b9a6cae6d3
+msgid "articles_page"
+msgstr "articles_page"
+
+#: ../../themes.rst:173 ../../themes.rst:206 ../../themes.rst:240
+#: ../../themes.rst:329 283875f54861414396ce8695d3002f7d
+#: b7400c136a8340df9eaa5e5f29b81766 ba00d04cfe6c4040bf704c17be73470f
+#: cdb81b11ea1a44d2890915c496eada40
+msgid "The current page of articles"
+msgstr "当前分页包含的文章的列表"
+
+#: ../../themes.rst:174 ../../themes.rst:207 ../../themes.rst:241
+#: ../../themes.rst:330 4fd0b5d101a74f23b8fb32e95b35af7f
+#: 6d6631ebf17e436ebd910cb778fa47e6 8869fe25c487475ea64c0ab80ee8c48b
+#: efd8e4bfc9234996870b90026c00f695
+msgid "articles_previous_page"
+msgstr "articles_previous_page"
+
+#: ../../themes.rst:174 ../../themes.rst:207 ../../themes.rst:241
+#: ../../themes.rst:330 228a67aba662491bb3e8b8f53d936921
+#: 4e0499da01e146d78c4c50ab293ceaec a9c5b7f1fb854f359f596f2de65510e9
+#: eaeb09fc611545ec87fbdbe32b7da599
+msgid "The previous page of articles (``None`` if page does not exist)"
+msgstr "前一分页包含的文章的列表(若没有前一页,此变量值为 ``None`` )"
+
+#: ../../themes.rst:176 ../../themes.rst:209 ../../themes.rst:243
+#: ../../themes.rst:332 44e81860c57c4136953fec9d390a1896
+#: 92e4766edf0d4f1a94801521a3ccc8c6 c7f7e0e63a5e4b3f838df1082628f71f
+#: eb4130c14eef4dc59383097aa4bfd9cc
+msgid "articles_next_page"
+msgstr "articles_next_page"
+
+#: ../../themes.rst:176 ../../themes.rst:209 ../../themes.rst:243
+#: ../../themes.rst:332 0aaccba1bbd843f3a13da1b8b206cb47
+#: 87d1cad4927745329bf74840147f3cae 9df65206ff0040caae56f0d2185e63d4
+#: a38e11e768ec40acafdc943d00fd1c39
+msgid "The next page of articles (``None`` if page does not exist)"
+msgstr "后一分页包含的文章的列表(若没有后一页,此变量值为 ``None`` )"
+
+#: ../../themes.rst:178 ../../themes.rst:211 ../../themes.rst:245
+#: ../../themes.rst:334 06c22ce247524bc59649f37ac570360d
+#: 3f913f031d1544049d4204b5c786e8eb 80e9ef1975ac43cb87b1cb1e2292a15d
+#: 9d50cd6bc33542ff9ec268664242cdac
+msgid "dates_paginator"
+msgstr "dates_paginator"
+
+#: ../../themes.rst:178 ../../themes.rst:211 470234ce4ff84c1282773c5e074a0984
+#: 66b61e29b0d94312be1924ffbf6a76f0
+msgid "A paginator object for the article list, ordered by date, ascending."
+msgstr "分页器对象,存放着以日期正序排列的文章列表。"
+
+#: ../../themes.rst:180 ../../themes.rst:213 ../../themes.rst:247
+#: ../../themes.rst:336 06688dad88b84be0a1b8a77904d3e36c
+#: 4c3336d0cc6146c0854e1a3b0a01226a c22fbf78288d40c2a7f53a0e05827bc9
+#: cbead4319b8449948907728edd1563e5
+msgid "dates_page"
+msgstr "dates_page"
+
+#: ../../themes.rst:180 ../../themes.rst:213 332ab164d0d14965a064f41289fd8b5a
+#: 9c0313b487514c1a8ea9ed741a022a98
+msgid "The current page of articles, ordered by date, ascending."
+msgstr "以日期正序(从旧到新)排列时,当前分页包含的文章的列表。"
+
+#: ../../themes.rst:182 ../../themes.rst:215 ../../themes.rst:249
+#: ../../themes.rst:338 225a16b1ca764c1297a6126e82294ea5
+#: 25b7b90357db4d999771a5dbb3ee46f0 f42233112a7940cfa0e448f72c254385
+#: fd276760afc04d66a3abb295db0c491b
+msgid "dates_previous_page"
+msgstr "dates_previous_page"
+
+#: ../../themes.rst:182 ../../themes.rst:215 ../../themes.rst:249
+#: ../../themes.rst:338 058e893b353046ffbdee082ea0ddcde2
+#: 0b15ab2a1e6e4d58a6648a72a2207ae5 13dc7929b6e9453bac9c30a9abf9a5f6
+#: 62de8d49e771412a89266c2d8731bd49
+msgid ""
+"The previous page of articles, ordered by date, ascending (``None`` if "
+"page does not exist)"
+msgstr ""
+"以日期正序(从旧到新)排列时,前一分页包含的文章的列表。"
+"(若没有前一页,此变量值为 ``None`` )"
+
+#: ../../themes.rst:184 ../../themes.rst:217 ../../themes.rst:251
+#: ../../themes.rst:340 156f78d11b96475a9d52085860a1e6c5
+#: 33b0c94c117c41ee955df750c1fd728c 5763fdf2c1cd43fc96013756029661d6
+#: add31a94f5dc490684aac08b7bcad8e5
+msgid "dates_next_page"
+msgstr "dates_next_page"
+
+#: ../../themes.rst:184 ../../themes.rst:217 ../../themes.rst:251
+#: ../../themes.rst:340 a61d56f03b5946899f9e951eba65df08
+#: ac60da91c10449cc8d519beb0b2f1102 cdfa2284c2c54da3a366d1deaefab551
+#: dc9ea16f9bb44d1d8d1032397aac1a8e
+msgid ""
+"The next page of articles, ordered by date, ascending (``None`` if page "
+"does not exist)"
+msgstr ""
+"以日期正序(从旧到新)排列时,后一分页包含的文章的列表。"
+"(若没有后一页,此变量值为 ``None`` )"
+
+#: ../../themes.rst:186 ../../themes.rst:219 ../../themes.rst:253
+#: ../../themes.rst:342 ../../themes.rst:493 501f30d99fc441f3b5070f8703c7e324
+#: 6a4735af4aa84d56bf745244c29f7e0c 8c9158f1b7f04d5ea07058d816be2e70
+#: cf1d564d80d34860a32fcddbac41375c e8c83819bbc0448799bae5ea19538100
+msgid "page_name"
+msgstr "page_name"
+
+#: ../../themes.rst:186 99f67be157844a6e85f1ebe6d40c9182
+msgid "'index' -- useful for pagination links"
+msgstr "值为 'index' ——在分页链接中很实用"
+
+#: ../../themes.rst:191 01c6da9f6c7b431d971fa0ec426f948f
+msgid "author.html"
+msgstr "author.html"
+
+#: ../../themes.rst:193 feee792cfdbf49b3a289762c8e0e0edb
+msgid ""
+"This template will be processed for each of the existing authors, with "
+"output generated according to the ``AUTHOR_SAVE_AS`` setting (`Default:` "
+"``author/{slug}.html``). If pagination is active, subsequent pages will "
+"by default reside at ``author/{slug}{number}.html``."
+msgstr ""
+"此模板会应用于每个已存在的作者上,并根据配置项 ``AUTHOR_SAVE_AS`` 确定输出路径"
+"( `默认值为:` ``author/{slug}.html`` )。如果启用了分页,后续页面会保存为 "
+"``author/{slug}{number}.html`` 。"
+
+#: ../../themes.rst:201 ../../themes.rst:448 ../../themes.rst:511
+#: 1f0784e3f85140afab2178a061897017 af9d9be813ae4f43be00ff6770a75fe5
+#: f9ea3f154b7f4268ab412ea2e6bf6c87
+msgid "author"
+msgstr "author"
+
+#: ../../themes.rst:201 01d284aaf9534cc5852557cc4063b6dc
+msgid "The name of the author being processed"
+msgstr "当前正在处理的作者名"
+
+#: ../../themes.rst:202 9a53c5cec5fb4fdd8df98bab9cfc77fa
+msgid "Articles by this author"
+msgstr "当前作者的文章"
+
+#: ../../themes.rst:203 4d5fc91dac964d63a9ac28ff07f44b97
+msgid "Articles by this author, but ordered by date, ascending"
+msgstr "当前作者的文章,以日期正序排列"
+
+#: ../../themes.rst:219 2f5aca7ff98c4de4bfdd82d6e57803e1
+msgid ""
+"AUTHOR_URL where everything after `{slug}` is removed -- useful for "
+"pagination links"
+msgstr ""
+"变量值与AUTHOR_URL一致,所有在 `{slug}` 之后的字符都会被删除——这对分页链接很有用"
+
+#: ../../themes.rst:225 a603e6fd07f7404ca86716249a4347ef
+msgid "category.html"
+msgstr "category.html"
+
+#: ../../themes.rst:227 10beee5e95394fd2ac3ab29e76cc06fc
+msgid ""
+"This template will be processed for each of the existing categories, with"
+" output generated according to the ``CATEGORY_SAVE_AS`` setting "
+"(`Default:` ``category/{slug}.html``). If pagination is active, "
+"subsequent pages will by default reside at "
+"``category/{slug}{number}.html``."
+msgstr ""
+"此模板会应用于每个已存在的分类上,根据设置项 ``CATEGORY_SAVE_AS`` 确定输出路径"
+"(`默认值为:` ``category/{slug}.html`` )。如果启用了分页,后续页面会保存为 "
+"``category/{slug}{number}.html`` 。"
+
+#: ../../themes.rst:235 ../../themes.rst:269 ../../themes.rst:452
+#: 04b6f1c1d1f04e0e806f898dda0df53e a8a2719723a44a04b0cc7516a9b8e811
+#: fc79984925564ea5b5dece084dbd3f15
+msgid "category"
+msgstr "category"
+
+#: ../../themes.rst:235 feb49105f74f4e93b8f7f3471327cc4b
+msgid "The name of the category being processed"
+msgstr "正在处理的分类名称"
+
+#: ../../themes.rst:236 fa6d2909a42446edbce322e4bdd74ca9
+msgid "Articles for this category"
+msgstr "此分类下的文章"
+
+#: ../../themes.rst:237 c89759eb3241470fb8f098ccb022f286
+msgid "Articles for this category, but ordered by date, ascending"
+msgstr "此分类下的文章,以日期正序排列"
+
+#: ../../themes.rst:245 ../../themes.rst:334 03985448999c44859adcb45b7a9da87c
+#: b5506c9105b843de92190998f7d07245
+msgid "A paginator object for the list of articles, ordered by date, ascending"
+msgstr "分页器对象,存放着以日期正序排列的文章列表"
+
+#: ../../themes.rst:247 ../../themes.rst:336 926e4184e9fc4288be3701737c8ea3cc
+#: 929ee1e0a49d4a7fa52343db55e6201b
+msgid "The current page of articles, ordered by date, ascending"
+msgstr "当前页面中的文章,以日期正序排列"
+
+#: ../../themes.rst:253 6b396d9ad87e4156a694c9e31663d935
+msgid ""
+"CATEGORY_URL where everything after `{slug}` is removed -- useful for "
+"pagination links"
+msgstr ""
+"变量值与CATEGORY_URL一致,所有在 `{slug}` 之后的字符都会被删除——这对分页链接很有用"
+
+#: ../../themes.rst:259 0c7b031962f14ca78b9cd72aa2de5b03
+msgid "article.html"
+msgstr "article.html"
+
+#: ../../themes.rst:261 1132a54c80564ac0a2706b026b263af7
+msgid ""
+"This template will be processed for each article, with output generated "
+"according to the ``ARTICLE_SAVE_AS`` setting (`Default:` "
+"``{slug}.html``). The following variables are available when rendering."
+msgstr ""
+"此模板会应用于文章上,根据设置项 ``ARTICLE_SAVE_AS`` 确定输出路径(`默认值为:` "
+"``{slug}.html`` )。在渲染文章过程中可以使用下列变量。"
+
+#: ../../themes.rst:268 6cc80575f5ac41e9bca4ce466d593f1d
+msgid "article"
+msgstr "article"
+
+#: ../../themes.rst:268 bbad6618dfa346c396dfa8cf02cb7ee7
+msgid "The article object to be displayed"
+msgstr "准备显示的文章对象"
+
+#: ../../themes.rst:269 4a9bcc18543a4d9eb533092d25bd59a2
+msgid "The name of the category for the current article"
+msgstr "当前文章所属分类的名称"
+
+#: ../../themes.rst:272 fdbbcc85d2aa406493ae4f0b4511e1a8
+msgid ""
+"Any metadata that you put in the header of the article source file will "
+"be available as fields on the ``article`` object. The field name will be "
+"the same as the name of the metadata field, except in all-lowercase "
+"characters."
+msgstr ""
+"文章源文件开头部分的元数据都会作为 ``article`` 对象的属性存在,属性名和元数据中"
+"指定的相同(但是是全小写的)。"
+
+#: ../../themes.rst:276 1c7d9a6b460849daacae3a205b6a59a6
+msgid ""
+"For example, you could add a field called `FacebookImage` to your article"
+" metadata, as shown below:"
+msgstr ""
+"例如,一篇文章源文件中添加了一个额外的元数据 `FacebookImage` :"
+
+#: ../../themes.rst:289 b934e5fbde064a7eb6d09405abc0ba1d
+msgid ""
+"This new metadata will be made available as `article.facebookimage` in "
+"your `article.html` template. This would allow you, for example, to "
+"specify an image for the Facebook open graph tags that will change for "
+"each article:"
+msgstr ""
+"此元数据在 `article.html` 模板中可以通过 `article.facebookimage` 获取。"
+"通过这种方式,就可以实现例如Facebook的动态打开标签:"
+
+#: ../../themes.rst:299 dacf9a5dc4de4a5398baf9632399be4b
+msgid "page.html"
+msgstr "page.html"
+
+#: ../../themes.rst:301 a65649dffe0e4e1fb26e38565a89fbf2
+msgid ""
+"This template will be processed for each page, with output generated "
+"according to the ``PAGE_SAVE_AS`` setting (`Default:` "
+"``pages/{slug}.html``). The following variables are available when "
+"rendering."
+msgstr ""
+"此模板会应用于页面上,根据设置项 ``PAGE_SAVE_AS`` 确定输出路径(`默认值为:` "
+"``pages/{slug}.html`` )。在渲染过程中可以使用下列变量。"
+
+#: ../../themes.rst:308 fb581643c0c04d6b89c3aa62bcdb5225
+msgid "page"
+msgstr "page"
+
+#: ../../themes.rst:308 02c821223e5448d7999f67d499844684
+msgid ""
+"The page object to be displayed. You can access its title, slug, and "
+"content."
+msgstr ""
+"准备显示的页面对象,可以从中获取标题、slug和具体内容。"
+
+#: ../../themes.rst:314 4f312193d3914a58be2a8e54e2fb61d8
+msgid "tag.html"
+msgstr "tag.html"
+
+#: ../../themes.rst:316 e96e2b0601e340878872dfcf5159575e
+msgid ""
+"This template will be processed for each tag, with output generated "
+"according to the ``TAG_SAVE_AS`` setting (`Default:` "
+"``tag/{slug}.html``). If pagination is active, subsequent pages will by "
+"default reside at ``tag/{slug}{number}.html``."
+msgstr ""
+"此模板会应用于标签页上,根据设置项 ``TAG_SAVE_AS`` 确定输出路径(`默认值为:` "
+"``tag/{slug}.html`` )。若启用了分页,后续页面默认存储为。``tag/{slug}{number}.html`` 。"
+
+#: ../../themes.rst:324 2c8332f2cdc144828b75e23937d3ef8e
+msgid "tag"
+msgstr "tag"
+
+#: ../../themes.rst:324 413cc4b9730a40d3aaee657a7d261daa
+msgid "The name of the tag being processed"
+msgstr "当前正在处理标签的名称"
+
+#: ../../themes.rst:325 726e68a5b71c4ba182afd29b36394c82
+msgid "Articles related to this tag"
+msgstr "和此标签关联的文章"
+
+#: ../../themes.rst:326 780cb9b0de1e4bc1842b8a1bc1ad9202
+msgid "Articles related to this tag, but ordered by date, ascending"
+msgstr "和此标签关联的文章,以日期正序排列"
+
+#: ../../themes.rst:342 c6fb1ba5f18b454ead7abdee5cded85b
+msgid ""
+"TAG_URL where everything after `{slug}` is removed -- useful for "
+"pagination links"
+msgstr ""
+"变量值与TAG_URL一致,所有在 `{slug}` 之后的字符都会被删除——这对分页链接很有用"
+
+#: ../../themes.rst:348 8786a045b390459fad281b06b7edae8c
+msgid "period_archives.html"
+msgstr "period_archives.html"
+
+#: ../../themes.rst:350 c2fad0f517ec40eb8309beca3794ca8b
+msgid ""
+"This template will be processed for each year of your posts if a path for"
+" ``YEAR_ARCHIVE_SAVE_AS`` is defined, each month if "
+"``MONTH_ARCHIVE_SAVE_AS`` is defined, and each day if "
+"``DAY_ARCHIVE_SAVE_AS`` is defined."
+msgstr ""
+"此模板用于生成归档页面, ``YEAR_ARCHIVE_SAVE_AS`` 、 ``MONTH_ARCHIVE_SAVE_AS`` "
+"与 ``DAY_ARCHIVE_SAVE_AS`` 分别对应着年、月、日的归档,只有指定了对应的路径才会生成"
+"归档页面。"
+
+#: ../../themes.rst:357 ../../themes.rst:394 ef52bf257ddc4687801b9438efa2660a
+#: f6eb6f96a622406cbf6d60a5c57276c7
+msgid "period"
+msgstr "period"
+
+#: ../../themes.rst:357 2d01d1314880482791134dbae86647d8
+msgid ""
+"A tuple of the form (`year`, `month`, `day`) that indicates the current "
+"time period. `year` and `day` are numbers while `month` is a string. This"
+" tuple only contains `year` if the time period is a given year. It "
+"contains both `year` and `month` if the time period is over years and "
+"months and so on."
+msgstr ""
+"一个元组,格式为 (`year`, `month`, `day`) ,指明了当前的时间段。 `year` 和 `day` "
+"为数字, `month` 则为字符串。当时间段以年给定时,此元组只会有 `year` ;当时间段以年"
+"和月给定时此元组中则只会包含 `year` 和 `month` ;以此类推。"
+
+#: ../../themes.rst:364 ../../themes.rst:397 2164d658ab7342839ea592c7f534c332
+#: ff99b9574a444dec9014c06b0c9b908e
+msgid "period_num"
+msgstr "period_num"
+
+#: ../../themes.rst:364 c4864711405b4f9fa565ac3bcc3a8803
+msgid ""
+"A tuple of the form (``year``, ``month``, ``day``), as in ``period``, "
+"except all values are numbers."
+msgstr ""
+"一个元组,格式为 (``year``, ``month``, ``day``) ,与 ``period`` 含义相同,"
+"只不过年月日都是以数字给出的。"
+
+#: ../../themes.rst:369 27affb54796f4855826eaf3506ed4ed5
+msgid ""
+"You can see an example of how to use `period` in the `\"simple\" theme "
+"period_archives.html template "
+"`_."
+msgstr ""
+"有关 `period` 的使用可以参考 `\"simple\" 主题中的period_archives.html模板 "
+"`_ ."
+
+#: ../../themes.rst:377 f556c7dd5ca5454888d19edf992c8dfa
+msgid "Listing and Linking to Period Archives"
+msgstr "列出归档与链接到归档"
+
+#: ../../themes.rst:379 d76f0d91885c42edb2652303f4a60cb6
+msgid ""
+"The ``period_archives`` variable can be used to generate a list of links "
+"to the set of period archives that Pelican generates. As a :ref:`common "
+"variable `, it is available for use in any template, so"
+" you can implement such an index in a custom direct template, or in a "
+"sidebar visible across different site pages."
+msgstr ""
+"对于Pelican给出的归档时间段, ``period_archives`` 可用于生成对应的链接列表。"
+"此变量作为 :ref:`通用变量 ` ,可在所有模板中使用。因此可以借此"
+"在自定义直接模板中或是侧边栏中实现链接索引。"
+
+#: ../../themes.rst:385 bf76ed577485401d8c5e180a2ea6b7fe
+msgid ""
+"``period_archives`` is a dict that may contain ``year``, ``month``, "
+"and/or ``day`` keys, depending on which ``*_ARCHIVE_SAVE_AS`` settings "
+"are enabled. The corresponding value is a list of dicts, where each dict "
+"in turn represents a time period (ordered according to the "
+"``NEWEST_FIRST_ARCHIVES`` setting) with the following keys and values:"
+msgstr ""
+"``period_archives`` 是一个字典,根据 ``*_ARCHIVE_SAVE_AS`` 设置的启用情况,"
+"其键对应为 ``year`` 、 ``month`` 与 ``day`` ,其值是包含字典的列表,每个字典依次"
+"表示一个时间段(顺序由 ``NEWEST_FIRST_ARCHIVES`` 设置决定),并包含以下键值对:"
+
+#: ../../themes.rst:392 d4b7e16101e24e13ac49a201f2e9b288
+msgid "Key"
+msgstr "键"
+
+#: ../../themes.rst:392 cda01b45b25c4b76bf38849c6b5368d0
+msgid "Value"
+msgstr "值"
+
+#: ../../themes.rst:394 ac2a1a43510a417fb10561cff9a5189e
+msgid ""
+"The same tuple as described in ``period_archives.html``, e.g. ``(2023, "
+"'June', 18)``."
+msgstr ""
+"一个元组,内容和 ``period_archives.html`` 中一样,例如 ``(2023, 'June', 18)`` 。"
+
+#: ../../themes.rst:397 fdae5356b80444dc84294a4e54b7a69e
+msgid ""
+"The same tuple as described in ``period_archives.html``, e.g. ``(2023, 6,"
+" 18)``."
+msgstr ""
+"一个元组,内容和 ``period_archives.html`` 中一样,例如 ``(2023, 6, 18)`` 。"
+
+#: ../../themes.rst:399 ../../themes.rst:476 ../../themes.rst:496
+#: ../../themes.rst:535 08cccff8dd0048a39054424ae58bfe24
+#: 3fe5b8e9d83a4cd28bfc96c745406432 c2d9d11c36e94278a94b3404e8335524
+#: c9ee356463204591986c9c17f8dfc8b4
+msgid "url"
+msgstr "url"
+
+#: ../../themes.rst:399 0c826cc879af4c8fa1fb4fceb92bb362
+msgid ""
+"The URL to the period archive page, e.g. ``posts/2023/06/18/``. This is "
+"controlled by the corresponding ``*_ARCHIVE_URL`` setting."
+msgstr ""
+"当前时间段归档页面的URL,例如 ``posts/2023/06/18/`` 。具体值由对应的设置项 "
+"``*_ARCHIVE_URL`` 决定。"
+
+#: ../../themes.rst:402 ../../themes.rst:463 ../../themes.rst:494
+#: ../../themes.rst:522 155a764c3763409c9bdf881881da49e4
+#: 8da502261f724333814ae130f068a454 d3eaeebea8a54785a4778eac9d436479
+#: ec45a7fbd4db443ab75b13b0fb2876e7
+msgid "save_as"
+msgstr "save_as"
+
+#: ../../themes.rst:402 29cd2e19b0f24fa8ac20e184aea547c5
+msgid ""
+"The path to the save location of the period archive page file, e.g. "
+"``posts/2023/06/18/index.html``. This is used internally by Pelican and "
+"is usually not relevant to themes."
+msgstr ""
+"当前时间段归档页面的存储路径,例如 ``posts/2023/06/18/index.html`` 。此路径用于"
+"Pelican内部处理,往往与主题无关。"
+
+#: ../../themes.rst:406 4bd641dcf26c4f61bf8d3c8667552501
+msgid ""
+"A list of :ref:`Article ` objects that fall under the "
+"time period."
+msgstr ""
+"一个列表,其中为当前时间段内所有文章的 :ref:`Article ` 对象。"
+
+#: ../../themes.rst:408 c59db635e66a4ed68b2648b6cd8691a4
+msgid ""
+"Same list as ``articles``, but ordered according to the "
+"``NEWEST_FIRST_ARCHIVES`` setting."
+msgstr ""
+"和 ``articles`` 相同的列表,但按照 ``NEWEST_FIRST_ARCHIVES`` 设置项进行排列。"
+
+#: ../../themes.rst:412 f096e1915d684d6b9bd0a1e5e034e5f0
+msgid "Here is an example of how ``period_archives`` can be used in a template:"
+msgstr "下面的例子展示了如何在模板中使用 ``period_archives`` :"
+
+#: ../../themes.rst:426 3f6144d2a3914984bc376ed6f33af53b
+msgid ""
+"You can change ``period_archives.month`` in the ``for`` statement to "
+"``period_archives.year`` or ``period_archives.day`` as appropriate, "
+"depending on the time period granularity desired."
+msgstr ""
+"你可以根据需要的时间粒度将 ``for`` 语句中的 ``period_archives.month`` 改为 "
+"``period_archives.year`` 或 ``period_archives.day`` 。"
+
+#: ../../themes.rst:432 ce9158ea38b54c5faeee718a7644ca5f
+msgid "Objects"
+msgstr "对象"
+
+#: ../../themes.rst:434 dd0725152df94c8f9e2d94439ccfa3a1
+msgid ""
+"Detail objects attributes that are available and useful in templates. Not"
+" all attributes are listed here, this is a selection of attributes "
+"considered useful in a template."
+msgstr ""
+"下面是对在模板中可用对象的属性的详细说明。以下仅列出了较常用的一些,并不是全部。"
+
+#: ../../themes.rst:441 af8644dff51348af8e52938bb8d6a0c8
+msgid "Article"
+msgstr "Article"
+
+#: ../../themes.rst:443 cc283674732243e5883a99b6a32166af
+msgid "The string representation of an Article is the `source_path` attribute."
+msgstr "Article对象的字符串表示即为 `source_path` 属性。"
+
+#: ../../themes.rst:446 ../../themes.rst:490 ../../themes.rst:509
+#: 3f2a9f3ea4c34e4ba7b83b17897f4b59 529f2387d2044534a0e3059defb2be46
+#: 97104fabe548459e9142574e4194afdb
+msgid "Attribute"
+msgstr "属性"
+
+#: ../../themes.rst:448 16d19143b7964b99953026728e8a5d4a
+msgid "The :ref:`Author ` of this article."
+msgstr "当前文章的 :ref:`Author `"
+
+#: ../../themes.rst:450 5a7ae4c0e9164288bd46cbf698ae01f8
+msgid "A list of :ref:`Authors ` of this article."
+msgstr "当前文章的多个 :ref:`Authors `"
+
+#: ../../themes.rst:452 982b4fe7fa4a41a5b3aed3a82168b462
+msgid "The :ref:`Category ` of this article."
+msgstr "当前文章的 :ref:`Category `"
+
+#: ../../themes.rst:454 ../../themes.rst:513 10ea5d1008fa4e7e9f11680013530b13
+#: 3bca890724c2487885fbfb34803f0a8b
+msgid "content"
+msgstr "content"
+
+#: ../../themes.rst:454 14973ea2fac140dbac7ed05f09f3b27d
+msgid "The rendered content of the article."
+msgstr "当前文章渲染完成的内容"
+
+#: ../../themes.rst:455 ../../themes.rst:514 1733ed5bfe0d421d96f074c2ea46c163
+#: b577071078d5413ba0199a4b5a64a926
+msgid "date"
+msgstr "date"
+
+#: ../../themes.rst:455 c99033f75c6c4aabb03c1ed24e530551
+msgid "Datetime object representing the article date."
+msgstr "当前文章的Datetime对象"
+
+#: ../../themes.rst:456 ../../themes.rst:515 9f8a6847d9f24162980e8bac2cc6e159
+#: c01cd89b410d45258311d8d62a0b3b24
+msgid "date_format"
+msgstr "date_format"
+
+#: ../../themes.rst:456 ../../themes.rst:515 14a1bee230d243da83e1a8f8e4817838
+#: 35bed86384a74210a5c5be86feb1ca83
+msgid "Either default date format or locale date format."
+msgstr "默认日期格式或是特定地区的日期格式"
+
+#: ../../themes.rst:457 ../../themes.rst:516 7c05e281dd0f4b7885653f977ce73b96
+#: 942fcdc259554437b58035fd53b3f430
+msgid "default_template"
+msgstr "default_template"
+
+#: ../../themes.rst:457 ../../themes.rst:516 754d4caf3da64863818cae661450c76b
+#: 7fc12db08b5641f388113c447d272970
+msgid "Default template name."
+msgstr "默认的模板名称"
+
+#: ../../themes.rst:458 ../../themes.rst:517 6434f76e9f2c425ab2e0f4e1df0d5eff
+#: 7a42be4c30d74d93b9778768d88f0d61
+msgid "in_default_lang"
+msgstr "in_default_lang"
+
+#: ../../themes.rst:458 ../../themes.rst:517 573f32f9ea2942b2849cb62bc4ad5b0d
+#: d9bbddf5ba92486faca7219d41907449
+msgid "Boolean representing if the article is written in the default language."
+msgstr "布尔值,用于表示当前文章是不是以默认语言写的。"
+
+#: ../../themes.rst:460 ../../themes.rst:519 c06096412cd6477f9a9505202b65a66b
+#: cf2ee07db2b544fb8bb5867fd47b4766
+msgid "lang"
+msgstr "lang"
+
+#: ../../themes.rst:460 ../../themes.rst:519 5feb94756b424a1f970b45ad224ab4df
+#: bb4db90299324791bcc00c9687d458e8
+msgid "Language of the article."
+msgstr "当前文章使用的语言。"
+
+#: ../../themes.rst:461 ../../themes.rst:520 3ddd8549af7f4c54bb4d1176ab4991fe
+#: f599ee9e24d24679ae8efe1b92bfabd2
+msgid "locale_date"
+msgstr "locale_date"
+
+#: ../../themes.rst:461 ../../themes.rst:520 492201eaff5d43bcb2a27d38dd414ea5
+#: bd9e52a8bfc24c89982c21a7ec33546b
+msgid "Date formatted by the `date_format`."
+msgstr "以 `date_format` 格式化后的日期。"
+
+#: ../../themes.rst:462 ../../themes.rst:521 298a8c49a9c54aa08e92063a205b4270
+#: 91a12b6902f140a285bd808fe527e942
+msgid "metadata"
+msgstr "metadata"
+
+#: ../../themes.rst:462 a6266566a3764288a3439022e3a374b5
+msgid "Article header metadata `dict`."
+msgstr "文章元数据的字典。"
+
+#: ../../themes.rst:463 8c8bb35d3d0a4fd4a8cbbe66da13e9f6
+msgid "Location to save the article page."
+msgstr "本篇文章生成保存的位置。"
+
+#: ../../themes.rst:464 ../../themes.rst:495 ../../themes.rst:523
+#: 02324ac5ed2f418d8aeabad7ef196271 265ffa91569c417faf9edfad84909010
+#: eb3abbd690c540dc8c8f96c457a949f1
+msgid "slug"
+msgstr "slug"
+
+#: ../../themes.rst:464 ../../themes.rst:495 ../../themes.rst:523
+#: 6ceb857897804044822f46787b8b2e24 6f893196b6f94121aa829816652d9b8d
+#: d07f43f0b91e4e0492db289b425a66ca
+msgid "Page slug."
+msgstr "推文的slug"
+
+#: ../../themes.rst:465 ../../themes.rst:524 2a6c951175234a94ad49fe66b5e0ac67
+#: 8cc7b9782316464ab8f4d93f44364487
+msgid "source_path"
+msgstr "source_path"
+
+#: ../../themes.rst:465 e56b161d0ff444db81b9ef5438205492
+msgid "Full system path of the article source file."
+msgstr "文章源文件的完整系统路径。"
+
+#: ../../themes.rst:466 ../../themes.rst:525 3288505bb4c94604a880a6e41e854174
+#: c6d1c1970adc4b7d851fc9a62579e2c6
+msgid "relative_source_path"
+msgstr "relative_source_path"
+
+#: ../../themes.rst:466 efa94005826e46b1a7ace439cfea8ecd
+msgid "Relative path from PATH_ to the article source file."
+msgstr "从 PATH_ 到当前文章源文件的相对路径。"
+
+#: ../../themes.rst:467 ../../themes.rst:526 0f57131e78b043bd974e545651a9eac6
+#: 4f11a741e9684957bc2ac83e1aa850ca
+msgid "status"
+msgstr "status"
+
+#: ../../themes.rst:467 ff6df46c090044a9afd9bafe55483999
+msgid "The article status, can be any of 'published' or 'draft'."
+msgstr "当前文章的状态,可能值为'published'或'draft'。"
+
+#: ../../themes.rst:469 ../../themes.rst:528 042ac3c1853845f99752c484e341dbde
+#: 59ec1f34a47b41959621ae638ee75bf6
+msgid "summary"
+msgstr "summary"
+
+#: ../../themes.rst:469 ../../themes.rst:528 f13f50f1e1024ce2bb1a3cd2d6bd0f45
+#: fe9173ab1a3b42a39d1ae3f24b2e13b6
+msgid "Rendered summary content."
+msgstr "渲染后的摘要内容。"
+
+#: ../../themes.rst:470 ../../themes.rst:529 455d848accf04082b6d0efe5c0451a8c
+#: 5acb76f85cdd47f0933b5c411f645ccd
+msgid "List of :ref:`Tag ` objects."
+msgstr ":ref:`Tag ` 对象的列表。"
+
+#: ../../themes.rst:472 ../../themes.rst:531 346843df50f64fcb8738d9a33a5991c0
+#: 5b43ff1b52e049a080dcfcf7c8532e55
+msgid "template"
+msgstr "template"
+
+#: ../../themes.rst:472 ../../themes.rst:531 1c98b0c5f84b438d9fbcdc7e564b532a
+#: 75b07b60fd0540ac998a7a5f8c755abb
+msgid "Template name to use for rendering."
+msgstr "用于渲染的模板名称"
+
+#: ../../themes.rst:473 ../../themes.rst:532 3da31ca0f3a74f1b807028b268704562
+#: 939c8b4e82c34cdc9e11fff8728e925a
+msgid "title"
+msgstr "title"
+
+#: ../../themes.rst:473 4f435f74edea49abba15e465cd65bc9b
+msgid "Title of the article."
+msgstr "当前文章的标题。"
+
+#: ../../themes.rst:474 ../../themes.rst:533 4c7c144119804fcc9b3aff5ba1cc1d60
+#: 60cfb30189bc4622b9f0f10d57e8cebb
+msgid "translations"
+msgstr "translations"
+
+#: ../../themes.rst:474 ../../themes.rst:533 5086f31401d243e5ba1e7d3a4dbc75ea
+#: 6c9e4cba9d80461787be1e245ea0e77c
+msgid "List of translations :ref:`Article ` objects."
+msgstr "当前文章所有翻译版本的 :ref:`Article ` 对象。"
+
+#: ../../themes.rst:476 0bbe38a721924758b16f7ed92bd47060
+msgid "URL to the article page."
+msgstr "文章页面的URL。"
+
+#: ../../themes.rst:485 6a1b829fd11b4a5aaa913e8ab5d8cb9a
+msgid "Author / Category / Tag"
+msgstr "Author / Category / Tag"
+
+#: ../../themes.rst:487 e74be0b0e7d7477791a14dc892a01970
+msgid "The string representation of those objects is the `name` attribute."
+msgstr "这些对象的字符串表示与 `name` 属性一致。"
+
+#: ../../themes.rst:492 95f673648cd347589e30bac268c62402
+msgid "name"
+msgstr "name"
+
+#: ../../themes.rst:492 c85c4552f17e47ce8e75aa83968488b7
+msgid "Name of this object [1]_."
+msgstr "当前对象的名称 [1]_ 。"
+
+#: ../../themes.rst:493 9ab58cf8d1c14233b5fab67bcff1ed07
+msgid "Author page name."
+msgstr "作者页面的名称。"
+
+#: ../../themes.rst:494 8924be38e76744c18a232657e3e53541
+msgid "Location to save the author page."
+msgstr "保存当前作者页面的路径。"
+
+#: ../../themes.rst:496 d836061f54274605b775c9a303e73355
+msgid "URL to the author page."
+msgstr "作者页面的URL。"
+
+#: ../../themes.rst:499 8a004fbcd1134a6aa51ecc83ead04eb3
+msgid "for Author object, coming from `:authors:` or `AUTHOR`."
+msgstr "对于Author对象,此属性值由 `:authors:` 或 `AUTHOR` 得来。"
+
+#: ../../themes.rst:504 015a5ef21bc1482baa94fe2ecc389be9
+msgid "Page"
+msgstr "Page"
+
+#: ../../themes.rst:506 e509492329b543b094117d9b207d40c1
+msgid "The string representation of a Page is the `source_path` attribute."
+msgstr "Page对象的字符串表示与 `source_path` 属性一致。"
+
+#: ../../themes.rst:511 acbd8346326242e3a6124d349d90c83f
+msgid "The :ref:`Author ` of this page."
+msgstr "当前页面的 :ref:`Author ` 。"
+
+#: ../../themes.rst:513 17df00ade1b84d89b90e0cf8949014c5
+msgid "The rendered content of the page."
+msgstr "当前页面渲染后的内容。"
+
+#: ../../themes.rst:514 50ec2f44596c4f849458456113b6688d
+msgid "Datetime object representing the page date."
+msgstr "当前页面日期对应的Datetime对象。"
+
+#: ../../themes.rst:521 29fd9eb25f1643bc844a9480618ddee3
+msgid "Page header metadata `dict`."
+msgstr "页面元数据的 `字典` 。"
+
+#: ../../themes.rst:522 caeac875f56345dfb4b871dd5cc47ff6
+msgid "Location to save the page."
+msgstr "保存页面的位置。"
+
+#: ../../themes.rst:524 ee2e9caa90d24f7f8106e82449194c5b
+msgid "Full system path of the page source file."
+msgstr "页面源文件的完整系统路径。"
+
+#: ../../themes.rst:525 4ac1a61bb61b491ab05058392e561819
+msgid "Relative path from PATH_ to the page source file."
+msgstr "页面源文件相对于 PATH_ 的相对路径。"
+
+#: ../../themes.rst:526 1e21d2a5056e4f56b1fb9aeb9b56240a
+msgid "The page status, can be any of 'published', 'hidden' or 'draft'."
+msgstr "页面的状态,可能值有'published'、'hidden'或者'draft'。"
+
+#: ../../themes.rst:532 0afb2b618cdd49d5b6f4c37dfa84c847
+msgid "Title of the page."
+msgstr "页面的标题。"
+
+#: ../../themes.rst:535 e4f719f69ae3495280e4953b0e948e02
+msgid "URL to the page."
+msgstr "页面的URL"
+
+#: ../../themes.rst:542 dbc8f1369a294996ac59e07d955880b6
+msgid "Feeds"
+msgstr "订阅源"
+
+#: ../../themes.rst:544 dbfa3023cab6407cb324cffe523c8533
+msgid ""
+"The feed variables changed in 3.0. Each variable now explicitly lists "
+"ATOM or RSS in the name. ATOM is still the default. Old themes will need "
+"to be updated. Here is a complete list of the feed variables::"
+msgstr ""
+"订阅源相关变量在3.0版本发生过变化。各变量现在都在名称中显示地表达了属于ATOM还是RSS。"
+"默认使用ATOM。旧的主题需要进行更新。下面是订阅源相关变量的完整列表:"
+
+#: ../../themes.rst:563 ee43d4b51dda44288f9786eefb8bf62c
+msgid "Inheritance"
+msgstr "继承"
+
+#: ../../themes.rst:565 a921f3b3e050422db6694600b6ae3379
+msgid ""
+"Since version 3.0, Pelican supports inheritance from the ``simple`` "
+"theme, so you can re-use the ``simple`` theme templates in your own "
+"themes."
+msgstr ""
+"从3.0版本开始,Pelican支持从 ``simple`` 主题继承,因此可以在你自己的主题中"
+"重用 ``simple`` 主题。"
+
+#: ../../themes.rst:568 36142bb5338a43a5bf0d9e53b52c0c05
+msgid ""
+"If one of the mandatory files in the ``templates/`` directory of your "
+"theme is missing, it will be replaced by the matching template from the "
+"``simple`` theme. So if the HTML structure of a template in the "
+"``simple`` theme is right for you, you don't have to write a new template"
+" from scratch."
+msgstr ""
+"如果 ``templates/`` 目录中缺失了的某些必须要有的文件,会自动使用 ``simple`` "
+"主题中的对应模板。因此如果 ``simple`` 主题中的一些模板正合你意,就没必要重新"
+"写个新的了。"
+
+#: ../../themes.rst:573 d4c77f03fe8049ed82ea0870e4384991
+#, python-format
+msgid ""
+"You can also extend templates from the ``simple`` theme in your own "
+"themes by using the ``{% extends %}`` directive as in the following "
+"example:"
+msgstr ""
+"你也可以使用 ``{% extends %}`` 指令在你自己的主题中扩展 ``simple`` 主题:"
+
+#: ../../themes.rst:584 6c8634ea148d48e68124f8b240de47c3
+msgid "Example"
+msgstr "例子"
+
+#: ../../themes.rst:586 c5845f57a75642a5a2a0c9018fd1dac0
+msgid "With this system, it is possible to create a theme with just two files."
+msgstr "利用这种自动继承的规则,只用两个文件就可以创建一个主题。"
+
+#: ../../themes.rst:589 c7ea4273a1ca4050968a1308a5a47c51
+msgid "base.html"
+msgstr "base.html"
+
+#: ../../themes.rst:591 4fa7a95ff17c4421bd39c45a9cd42f8f
+msgid "The first file is the ``templates/base.html`` template:"
+msgstr "第一个文件是 ``templates/base.html`` 模板:"
+
+#: ../../themes.rst:602 87484a8d548449b4b58d6773201ddf67
+msgid ""
+"On the first line, we extend the ``base.html`` template from the "
+"``simple`` theme, so we don't have to rewrite the entire file."
+msgstr ""
+"第一行中,从 ``simple`` 主题中扩展了 ``base.html`` 模板,因此无需重写整个文件。"
+
+#: ../../themes.rst:604 20209f5462c24d3b9918f14db3dc9f0c
+msgid ""
+"On the third line, we open the ``head`` block which has already been "
+"defined in the ``simple`` theme."
+msgstr ""
+"第三行,我们开始声明 ``head`` 块,这个块已在 ``simple`` 中进行了定义。"
+
+#: ../../themes.rst:606 9d6577b07bdd4eab814a188effd796c7
+msgid ""
+"On the fourth line, the function ``super()`` keeps the content previously"
+" inserted in the ``head`` block."
+msgstr ""
+"第四行中, ``super()`` 函数使得已添加到 ``head`` 块中的前序内容得以保留。"
+
+#: ../../themes.rst:608 157f34425e4d4b119c97bc7a9cb513ff
+msgid "On the fifth line, we append a stylesheet to the page."
+msgstr "第五行为页面添加了一个样式表。"
+
+#: ../../themes.rst:609 bf52b4834d67475194b43b35c2a9dfde
+msgid "On the last line, we close the ``head`` block."
+msgstr "最后一行结束对 ``head`` 块的声明。"
+
+#: ../../themes.rst:611 968532a3244e436fba5b6df5c996888d
+msgid ""
+"This file will be extended by all the other templates, so the stylesheet "
+"will be linked from all pages."
+msgstr ""
+"其他所有模板都会在此文件基础上进行扩展,因此样式表会被所有页面引用。"
+
+#: ../../themes.rst:615 62629bf8d5ea4271a598b95ebede4757
+msgid "style.css"
+msgstr "style.css"
+
+#: ../../themes.rst:617 e8e0ee6348e84ff590fe5afebe39ec63
+msgid "The second file is the ``static/css/style.css`` CSS stylesheet:"
+msgstr "第二个文件是CSS样式表 ``static/css/style.css`` :"
+
+#: ../../themes.rst:661 80ec5c70bd9b49e7b22718cc18e46b84
+msgid "Download"
+msgstr "下载"
+
+#: ../../themes.rst:663 acf9dfc296794b3c928572374b39926e
+msgid ""
+"You can download this example theme :download:`here <_static/theme-"
+"basic.zip>`."
+msgstr ""
+"可以在 :download:`这里 <_static/theme-basic.zip>` 下载此例。"
+
+#~ msgid ""
+#~ "To generate its HTML output, Pelican "
+#~ "uses the `Jinja "
+#~ "`_ templating engine"
+#~ " due to its flexibility and "
+#~ "straightforward syntax. If you want to"
+#~ " create your own theme, feel free "
+#~ "to take inspiration from the `\"simple\""
+#~ " theme "
+#~ "`_."
+#~ msgstr ""
+
+#~ msgid ""
+#~ "You can see an example of how "
+#~ "to use `period` in the `\"simple\" "
+#~ "theme period_archives.html template "
+#~ "`_."
+#~ msgstr ""
diff --git a/docs/locale/zh_CN/LC_MESSAGES/tips.po b/docs/locale/zh_CN/LC_MESSAGES/tips.po
new file mode 100644
index 00000000..4ecdcb1b
--- /dev/null
+++ b/docs/locale/zh_CN/LC_MESSAGES/tips.po
@@ -0,0 +1,679 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) 2010–2024
+# This file is distributed under the same license as the PELICAN package.
+# FIRST AUTHOR , 2024.
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: PELICAN 4\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2024-06-25 20:36+0800\n"
+"PO-Revision-Date: 2024-06-27 19:00+0800\n"
+"Last-Translator: GeorgeHu \n"
+"Language: zh_CN\n"
+"Language-Team: zh_CN \n"
+"Plural-Forms: nplurals=1; plural=0;\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=utf-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Generated-By: Babel 2.15.0\n"
+
+#: ../../tips.rst:2 415f61a654104cf4826423e3aa1d3807
+msgid "Tips"
+msgstr "小技巧"
+
+#: ../../tips.rst:4 1bc50144d85845f3a7f21f9ef87bba44
+msgid "Here are some tips about Pelican that you might find useful."
+msgstr "以下是一些实用的小技巧。"
+
+#: ../../tips.rst:7 ../../tips.rst:264 d9115f4b162d46e6aa89d56309c1ec41
+#: e693dc009e5c466d99655b705223f300
+msgid "Custom 404 Pages"
+msgstr "自定义404页面"
+
+#: ../../tips.rst:9 5c7cd70793f44d3c9fcf63779755d62b
+msgid ""
+"When a browser requests a resource that the web server cannot find, the "
+"web server usually displays a generic \"File not found\" (404) error page"
+" that can be stark and unsightly. One way to provide an error page that "
+"matches the theme of your site is to create a custom 404 page (*not* an "
+"article), such as this Markdown-formatted example stored in "
+"``content/pages/404.md``::"
+msgstr ""
+"当浏览器请求的资源无法在服务器中找到时,web服务器常常会显示一个通用的“File not "
+"found 404”的错误页面,这可能会不太美观。为了能使用一个与站点主题相匹配的404页面"
+"(注意是页面而 **不是** 文章),例如下面这个Markdown格式的例子,将此文件存为了 "
+"``content/pages/404.md`` :"
+
+#: ../../tips.rst:22 cab28bb6b2a548a09f8cc6e4778f1a78
+msgid ""
+"The next step is to configure your web server to display this custom page"
+" instead of its default 404 page. For Nginx, add the following to your "
+"configuration file's ``location`` block::"
+msgstr ""
+"接下来就是要配置web服务器,使其显示此自定义页面而不是默认的404页面。例如对于Nginx,"
+"在配置文件的 ``location`` 块中添加下面的命令:"
+
+#: ../../tips.rst:28 f8acbc4d00de4cfb8dfd9358a8168c14
+msgid "For Apache::"
+msgstr "对于Apache:"
+
+#: ../../tips.rst:32 3701d02f6dba4936a86a9fbb226261e8
+msgid ""
+"For Amazon S3, first navigate to the ``Static Site Hosting`` menu in the "
+"bucket settings on your AWS console. From there::"
+msgstr ""
+"对于Amazon S3实例,先在控制台的设置中找到 ``Static Site Hosting`` ,并添加:"
+
+#: ../../tips.rst:38 4d111f7cca2e49828e343ff889847358
+msgid "Publishing to GitHub Pages"
+msgstr "发布到GitHub Pages"
+
+#: ../../tips.rst:40 f7fa83b00f6d4dd58d6f119725474538
+msgid ""
+"If you use `GitHub `_ for your Pelican site you can "
+"publish your site to `GitHub Pages `_ for "
+"free. Your site will be published to ``https://.github.io`` if "
+"it's a user or organization site or to "
+"``https://.github.io/`` if it's a project site. "
+"It's also possible to `use a custom domain with GitHub Pages "
+"`_."
+msgstr ""
+"如果将Pelican站点放在了 `GitHub `_ 上,那么你就可以将站点"
+"免费发布在 `GitHub Pages `_ 上。如果是用户或组织的"
+"站点,发布的地址为 ``https://.github.io`` ;如果是某个项目的站点,"
+"发布的地址则为 ``https://.github.io/`` 。当然也可以 "
+"`在GitHub Pages上使用自定义域名 `_ 。"
+
+#: ../../tips.rst:46 a3167f2a605d44288b83d66f052e8cdd
+msgid ""
+"There are `two ways to publish a site to GitHub Pages "
+"`_:"
+msgstr ""
+"总的来说,有 `两种将站点发布到GitHub Pages的方法 `_ :"
+
+#: ../../tips.rst:48 b2f270c5a15d4e3e92331c3c37db25dd
+msgid ""
+"**Publishing from a branch:** run ``pelican`` locally and push the output"
+" directory to a special branch of your GitHub repo. GitHub will then "
+"publish the contents of this branch to your GitHub Pages site."
+msgstr ""
+"**从某一分支发布:** 在本地运行 ``pelican`` 后将输出文件夹push到GitHub仓库的"
+"某一分支。GitHub就会将该分支的内容发布到GitHub Pages上。"
+
+#: ../../tips.rst:51 4ffdb550d8bf468dbfe4d32dfcda21cd
+msgid ""
+"**Publishing with a custom GitHub Actions workflow:** just push the "
+"source files of your Pelican site to your GitHub repo's default branch "
+"and have a custom GitHub Actions workflow run ``pelican`` for you to "
+"generate the output directory and publish it to your GitHub Pages site. "
+"This way you don't need to run ``pelican`` locally. You can even edit "
+"your site's source files using GitHub's web interface and any changes "
+"that you commit will be published."
+msgstr ""
+"**从自定义GitHub Actions工作流发布:** 将内容源文件推送到GitHub仓库的默认分支,"
+"然后在GitHub Actions工作流中执行 ``pelican`` 以生成输出文件夹,最后将其发布到你"
+"的GitHub Pages站点。此种方法下就无需在本地执行 ``pelican`` 命令了。甚至可以直接"
+"在GitHub的网页中在线修改站点内容源文件。"
+
+#: ../../tips.rst:60 0e9c34ce1a5948098a5d0812eb8ac1b4
+msgid "Publishing a Project Site to GitHub Pages from a Branch"
+msgstr "从某一分支发布项目站点到GitHub Pages"
+
+#: ../../tips.rst:62 5190ebea8d8b4542ac9ecb98c297594e
+msgid ""
+"To publish a Pelican site as a Project Page you need to *push* the "
+"content of the ``output`` dir generated by Pelican to a repository's "
+"``gh-pages`` branch on GitHub."
+msgstr ""
+"要将Pelican站点发布为项目页面,你需要将Pelican生成的 ``output`` 目录 "
+"**push** 到GitHub仓库的 ``gh-pages`` 分支。"
+
+#: ../../tips.rst:66 e12298010e9745b59d60d31ae909fd4c
+msgid ""
+"The excellent `ghp-import `_, which"
+" can be installed with ``pip``, makes this process really easy."
+msgstr ""
+"可通过 ``pip`` 安装的 `ghp-import `_ "
+"使这一步变得非常简单。"
+
+#: ../../tips.rst:69 cd5a5847355846dd81a0ad37858358f2
+msgid ""
+"For example, if the source of your Pelican site is contained in a GitHub "
+"repository, and if you want to publish that Pelican site in the form of "
+"Project Pages to this repository, you can then use the following::"
+msgstr ""
+"例如,当Pelican站点的源文件已经包含在GitHub仓库中时,可以将其作为此仓库的项目页面:"
+
+#: ../../tips.rst:77 18d3e7316a5a48acb337c3c67e94084c
+msgid ""
+"The ``ghp-import output`` command updates the local ``gh-pages`` branch "
+"with the content of the ``output`` directory (creating the branch if it "
+"doesn't already exist). The ``git push origin gh-pages`` command updates "
+"the remote ``gh-pages`` branch, effectively publishing the Pelican site."
+msgstr ""
+"``ghp-import output`` 命令会用 ``output`` 目录下的内容更新本地的 ``gh-pages`` "
+"分支(如果此分支不存在则会先创建)。接着再用 ``git push origin gh-pages`` "
+"命令更新远程分支 ``gh-pages`` ,如此就能够发布Pelican站点了。"
+
+#: ../../tips.rst:84 cc8b9d96da674850b39373728000f722
+msgid ""
+"The ``github`` target of the Makefile (and the ``gh_pages`` task of "
+"``tasks.py``) created by the ``pelican-quickstart`` command publishes the"
+" Pelican site as Project Pages, as described above."
+msgstr ""
+"``pelican-quickstart`` 在Makefile文件中所生成的 ``github`` 目标(以及为 "
+"``gh_pages`` 任务生成的 ``tasks.py`` )使得Pelican站点能像上面描述的那样被发布"
+"为项目页面。"
+
+#: ../../tips.rst:89 41c7b129fd334796848c4d75404dbe81
+msgid "Publishing a User Site to GitHub Pages from a Branch"
+msgstr "从某一分支发布用户站点到GitHub Pages"
+
+#: ../../tips.rst:91 b379f950927d484ba91fbe649a248cfe
+msgid ""
+"To publish a Pelican site in the form of User Pages, you need to *push* "
+"the content of the ``output`` dir generated by Pelican to the ``main`` "
+"branch of your ``.github.io`` repository on GitHub."
+msgstr ""
+"要以用户页面形式发布Pelican站点,你需要将Pelican生成的 ``output`` 目录内容 "
+"**push** 到 ``.github.io`` 仓库的 ``master`` 分支上。"
+
+#: ../../tips.rst:95 6d1bd6c0ff25494e997c4efbdcd1d861
+msgid "Again, you can take advantage of ``ghp-import``::"
+msgstr "同样的,此处也可以使用 ``ghp-import`` :"
+
+#: ../../tips.rst:101 45fb7ba534af4f7d828e1630e591c02a
+msgid ""
+"The ``git push`` command pushes the local ``gh-pages`` branch (freshly "
+"updated by the ``ghp-import`` command) to the ``elemoine.github.io`` "
+"repository's ``main`` branch on GitHub."
+msgstr ""
+"``git push`` 命令将本地的 ``gh-pages`` 分支(此分支在刚刚通过 ``ghp-import`` "
+"命令进行了更新)push到了GitHub仓库 ``elemoine.github.io`` 的 ``master`` 分支。"
+
+#: ../../tips.rst:107 b105e7dd1aef441896c0f59166808113
+msgid ""
+"To publish your Pelican site as User Pages, feel free to adjust the "
+"``github`` target of the Makefile."
+msgstr ""
+"要将Pelican站点发布为用户页面,可以根据需要修改Makefile中的 ``github`` 目标。"
+
+#: ../../tips.rst:110 87a89a932eec40e8bfdd5c756f4d54fc
+msgid ""
+"Another option for publishing to User Pages is to generate the output "
+"files in the root directory of the project."
+msgstr ""
+"发布用户页面的另一种方法就是将输出文件生成在项目的根目录下。"
+
+#: ../../tips.rst:113 dab76a45349c432cb4b763484661ec2c
+msgid ""
+"For example, your main project folder is ``.github.io`` and you"
+" can create the Pelican project in a subdirectory called ``Pelican``. "
+"Then from inside the ``Pelican`` folder you can run::"
+msgstr ""
+"例如,项目的主文件夹是 ``.github.io`` ,你可以在子目录 ``Pelican`` "
+"中创建一个Pelican项目。然后你可以在这个 ``Pelican`` 文件夹中执行下面的命令:"
+
+#: ../../tips.rst:119 7f13464c92f14cc18f8c00f7dae78f93
+msgid ""
+"Now you can push the whole project ``.github.io`` to the main "
+"branch of your GitHub repository::"
+msgstr ""
+"接着可以将整个项目 ``.github.io`` push到GitHub仓库的master分支中:"
+
+#: ../../tips.rst:124 e82ff566e32b4696863aa04216aaf355
+msgid "(assuming origin is set to your remote repository)."
+msgstr "(此处假设远程仓库命名为origin)。"
+
+#: ../../tips.rst:127 1958522ba7c34537855505f1e64c7b43
+msgid "Publishing to GitHub Pages Using a Custom GitHub Actions Workflow"
+msgstr "使用自定义GitHub Actions工作流将站点发布GitHub Pages中"
+
+#: ../../tips.rst:129 19c47b80d248451facd8407bd960b527
+msgid ""
+"Pelican-powered sites can be published to GitHub Pages via a `custom "
+"workflow "
+"`_."
+" To use it:"
+msgstr ""
+"Pelican已经给你准备了一份 `自定义工作流 "
+"`_"
+" ,你可以直接使用此工作流发布站点:"
+
+#: ../../tips.rst:133 bdc132ef5b974d1eae684d8118e4d914
+msgid ""
+"Enable GitHub Pages in your repo: go to **Settings → Pages** and choose "
+"**GitHub Actions** for the **Source** setting."
+msgstr ""
+"首先为仓库开启GitHub Pages: **Settings → Pages** 中有个 **Source** 设置项,"
+"将其选择为 **GitHub Actions** 。"
+
+#: ../../tips.rst:136 d7d197c176bd4127a75cfaf9dd29212b
+msgid ""
+"Commit a ``.github/workflows/pelican.yml`` file to your repo with these "
+"contents:"
+msgstr ""
+"往你的仓库中commit一个 ``.github/workflows/pelican.yml`` 文件,文件内容如下:"
+
+#: ../../tips.rst:155 656a2b783b6043f2ac26b1e7b342732e
+msgid ""
+"You may want to replace the ``@main`` with the ID of a specific commit in"
+" this repo in order to pin the version of the reusable workflow that "
+"you're using: ``uses: "
+"getpelican/pelican/.github/workflows/github_pages.yml@``. If "
+"you do this you might want to get Dependabot to send you automated pull "
+"requests to update that commit ID whenever new versions of this workflow "
+"are published, like so:"
+msgstr "你可能想要将 ``@main`` 替换为这个仓库中某个特定commit的ID,以便将你使用的"
+"可重用工作流的版本固定下来,此时,可以使用 ``uses: getpelican/pelican/.github/workflows/"
+"github_pages.yml@`` 。在这种情况下,你可能想让Dependabot自动向你发送"
+"PR,以便在发布新版本的工作流时更新commit ID,如下所示:"
+
+#: ../../tips.rst:172 0e2e10f42d6142e1b2f9d2251879ffad
+msgid ""
+"See `GitHub's docs about using Dependabot to keep your actions up to date"
+" `_."
+msgstr "请参阅 `GitHub文档 `_ ,了解如何使用Dependabot使您的action保持最新。"
+
+#: ../../tips.rst:174 2475397adfbb48af9a1d16fc0a24d9b9
+msgid ""
+"Go to the **Actions** tab in your repo "
+"(``https://github.com///actions``) and you should "
+"see a **Deploy to GitHub Pages** action running."
+msgstr ""
+"选中仓库的 **Actions** 标签栏( ``https://github.com//"
+"/actions`` ),此时你应该会看到已经有一个名为 **Deploy to GitHub Pages** 的"
+"action正在运行。"
+
+#: ../../tips.rst:178 df30a15c460b442796f7f2007c283f32
+msgid ""
+"Once the action completes you should see your Pelican site deployed at "
+"your repo's GitHub Pages URL: ``https://.github.io`` for a user"
+" or organization site or ``https://.github.io/>`` "
+"for a project site."
+msgstr ""
+"当此action执行完成,就能够通过仓库的GitHub Pages地址 ``https://."
+"github.io`` 看到部署好了的用户或组织站点了,对于项目站点,可通过 ``https://"
+".github.io/`` 访问。"
+
+#: ../../tips.rst:183 f79963fcfd204f2780ff536516e6d407
+msgid "Notes:"
+msgstr "注意事项:"
+
+#: ../../tips.rst:185 3a2dc6a36d38454e85265ef35c5e8010
+msgid ""
+"You don't need to set ``SITEURL`` or ``FEED_DOMAIN`` in your Pelican "
+"settings: the workflow will set them correctly for you"
+msgstr ""
+"无需在Pelican配置文件中设置 ``SITEURL`` ,工作流会帮你进行设置。"
+
+#: ../../tips.rst:188 ea406746a7db49dfa10de025a3be4a31
+msgid ""
+"You don't need to commit your ``--output`` / ``OUTPUT_PATH`` directory "
+"(``output/``) to git: the workflow will run ``pelican`` to build the "
+"output directory for you on GitHub Actions"
+msgstr ""
+"无需commit ``--output`` 或 ``OUTPUT_PATH`` 所指定的目录( ``output/`` ):"
+"工作流会自己执行 ``pelican`` 命令来构建输出目录。"
+
+#: ../../tips.rst:192 a92a4068ac294a22ac80b1db68090634
+msgid ""
+"See `GitHub's docs about reusable workflows "
+"`_ "
+"for more information."
+msgstr ""
+"更多信息请参阅 `GitHub可重用工作流文档 `_ 。"
+
+#: ../../tips.rst:195 1264d8a048aa4bd7878845ba2dac0d0d
+msgid ""
+"A number of optional inputs can be added to the ``with:`` block when "
+"calling the workflow, for example:"
+msgstr ""
+"有一些可选输入可以添加到工作流的 ``with:`` 块中:"
+
+#: ../../tips.rst:206 3faf65d7567244e3bc65a15dc84cf247
+msgid "Here's the complete list of workflow inputs:"
+msgstr "下面是工作流可用输入参数的完整列表:"
+
+#: ../../tips.rst:209 37919ce86ddb4546bd191440ba1c5b9a
+msgid "Name"
+msgstr "名称"
+
+#: ../../tips.rst:209 645ae6a27c7b40ecbc795dbd698b0649
+msgid "Required"
+msgstr "是否必需"
+
+#: ../../tips.rst:209 18917f8f278440e38882a4f1ca62fc8f
+msgid "Description"
+msgstr "描述"
+
+#: ../../tips.rst:209 99be24eafb6d43578e6eabba25f568fe
+msgid "Type"
+msgstr "值的类型"
+
+#: ../../tips.rst:209 24860d0693b84e6c9297f8733b338824
+msgid "Default"
+msgstr "默认值"
+
+#: ../../tips.rst:211 7e9bb7ea151c4e8c99116dd4decbe3c1
+msgid "``settings``"
+msgstr "``settings``"
+
+#: ../../tips.rst:211 647c4173846f4057920030c8f774d5ea
+msgid "Yes"
+msgstr "是"
+
+#: ../../tips.rst:211 05c57822d0a249de9718a9a3c56e9e56
+msgid ""
+"The path to your Pelican settings file (``pelican``'s ``--settings`` "
+"option), for example: ``\"publishconf.py\"``"
+msgstr ""
+"Pelican配置文件的路径(会被用于 ``pelican`` 命令的 ``--settings`` 选项),例如 "
+"``\"publishconf.py\"`` 。"
+
+#: ../../tips.rst:211 ../../tips.rst:216 ../../tips.rst:223 ../../tips.rst:227
+#: ../../tips.rst:231 ../../tips.rst:237 ../../tips.rst:243
+#: 4e21f78e86f049048a800ddd5c51e230 618fd4eb66ff45b29c98df87b145613c
+#: 93083ab6eb974293820f40d16349c100 9684f50652484820b924109f31418cd7
+#: 9df48660f1a84fe1af952256c7b58aec cef3fc9239d941969fda711c74994d8c
+#: d09fff93593844cfbb0b270b4cd74193
+msgid "string"
+msgstr "string"
+
+#: ../../tips.rst:216 f867df810054493f9d6be16271822ddb
+msgid "``requirements``"
+msgstr "``requirements``"
+
+#: ../../tips.rst:216 ../../tips.rst:223 ../../tips.rst:227 ../../tips.rst:231
+#: ../../tips.rst:237 ../../tips.rst:243 019e197dd56b44229549da7a2421ce37
+#: 636f76c7f1ca4c61bcea4bbe39a4eb1f 671a0ff87e294e7ab0ac8cdf70fdfe1d
+#: 848f43cf99c447a595f4760e2cf25f2b b425d772694640d0a7bae06c236fa1a2
+#: d145c924e4f348f5ad24b51286ce61e6
+msgid "No"
+msgstr "否"
+
+#: ../../tips.rst:216 0d5ee9c193994b2cac7757e881f01a42
+msgid ""
+"The Python requirements to install, for example to enable markdown and "
+"typogrify use: ``\"pelican[markdown] typogrify\"`` or if you have a "
+"requirements file: ``\"-r requirements.txt\"``"
+msgstr ""
+"需要安装的Python模块,例如要开启markdown和typogrify,可指定 ``\"pelican[markdown] "
+"typogrify\"`` ,或者可以指定一个requirements文件: ``\"-r requirements.txt\"`` "
+
+#: ../../tips.rst:216 67298d60de17486dbc1b6841f2c433b9
+msgid "``\"pelican\"``"
+msgstr "``\"pelican\"``"
+
+#: ../../tips.rst:223 219a8d185ac440329e8aa7306e55e708
+msgid "``output-path``"
+msgstr "``output-path``"
+
+#: ../../tips.rst:223 21a3530e340349afa64d7eb69b393c98
+msgid "Where to output the generated files (``pelican``'s ``--output`` option)"
+msgstr "生成文件的输出位置(会被用于 ``pelican`` 命令的 ``--output`` 选项)"
+
+#: ../../tips.rst:223 dea97da0dfc24941b8850d1d26ea3cd3
+msgid "``\"output/\"``"
+msgstr "``\"output/\"``"
+
+#: ../../tips.rst:227 688ac4687d7841629137bf97ce97deee
+msgid "``theme``"
+msgstr "``theme``"
+
+#: ../../tips.rst:227 2c2e6b6d8a6044c0ba64d00ea1b12d40
+msgid ""
+"The GitHub repo URL of a custom theme to use, for example: "
+"``\"https://github.com/seanh/sidecar.git\"``"
+msgstr ""
+"要使用的自定义主题的GitHub仓库URL,例如: ``\"https://github.com/seanh/"
+"sidecar.git\"``"
+
+#: ../../tips.rst:227 bd63884f7e60412d9a6cccc5da9c47ac
+msgid "``\"\"``"
+msgstr "``\"\"``"
+
+#: ../../tips.rst:231 9527d9e89d704210baff0bb6e3e23b20
+msgid "``python``"
+msgstr "``python``"
+
+#: ../../tips.rst:231 1aa44193e62647c0ba275507ea84b42c
+msgid ""
+"The version of Python to use to build the site, for example: ``\"3.12\"``"
+" (to use the most recent version of Python 3.12, this is faster) or "
+"``\"3.12.1\"`` (to use an exact version, slower)"
+msgstr ""
+"构建站点时使用的Python版本,例如: ``\"3.12\"`` 或 ``\"3.12.1\"``"
+
+#: ../../tips.rst:231 d182ae2dd44c482fb3f2373a7d97087c
+msgid "``\"3.12\"``"
+msgstr "``\"3.12\"``"
+
+#: ../../tips.rst:237 dc65b4e578e24d179c38066871c2c572
+msgid "``siteurl``"
+msgstr "``siteurl``"
+
+#: ../../tips.rst:237 5909de5d60224c7b875753f88fd13296
+msgid ""
+"The base URL of your web site (Pelican's ``SITEURL`` setting). If not "
+"passed this will default to the URL of your GitHub Pages site, which is "
+"correct in most cases."
+msgstr ""
+"站点的基URL,会用于配置项 ``SITEURL`` 。若未指定,默认值为GitHub Pages站点"
+"的URL,这适用于大部分情况。"
+
+#: ../../tips.rst:237 ../../tips.rst:243 0c0b86aa4b984615afb3564b76e379ff
+#: c7ddd6347a7f4467b31aaa8f4d4a2309
+msgid "The URL of your GitHub Pages site."
+msgstr "GitHub Pages站点的URL"
+
+#: ../../tips.rst:243 af7d2b52c5504ac2b69490a18d14f80f
+msgid "``feed_domain``"
+msgstr "``feed_domain``"
+
+#: ../../tips.rst:243 2cc126862a8047c286381aa258aad013
+msgid ""
+"The domain to be prepended to feed URLs (Pelican's ``FEED_DOMAIN`` "
+"setting). If not passed this will default to the URL of your GitHub Pages"
+" site, which is correct in most cases."
+msgstr ""
+"订阅源URL前要附加的域名,会用于配置项 ``FEED_DOMAIN`` 。若未指定,默认值为"
+"GitHub Pages站点的URL,这适用于大部分情况。"
+
+#: ../../tips.rst:252 b86ab8a1fa24447d99becc592411010e
+msgid "\"Insecure content\" warnings from browsers"
+msgstr "浏览器报“不安全的内容(Insecure content)”警告"
+
+#: ../../tips.rst:254 c81d5f8889c14a069e55fe7472a238f2
+msgid ""
+"If your site uses ``https://`` and is broken because the browser is "
+"blocking network requests (for example for CSS files) due to \"insecure "
+"content\" this may be because GitHub Pages is generating ``http://`` URLs"
+" for your site."
+msgstr ""
+"当站点使用 ``https://`` 时,可能会损坏,无法正常显示,这是由于浏览器阻拦了一些"
+"对“不安全内容”的网络请求。可能的原因之一是GitHub Pages给你的站点生成了 ``http://`` "
+"URL。"
+
+#: ../../tips.rst:258 2a53f882b7e645149d18ce81757b9758
+msgid ""
+"To fix this go into your site repo's settings and enable the **Enforce "
+"HTTPS** setting: go to **Settings → Pages** and check **Enforce HTTPS**. "
+"Then re-run the workflow to re-deploy your site. Alternatively, you can "
+"use the workflow's ``siteurl`` and ``feed_domain`` settings."
+msgstr ""
+"要想解决这一问题,需要为站点所在仓库开启 **强制使用HTTPS** :点击 **Settings → Pages** "
+"并在其中勾选 **Enforce HTTPS** ,接着再重新执行工作流以重新部署站点。也可以尝试"
+"通过配置 ``siteurl`` 与 ``feed_domain`` 解决问题。"
+
+#: ../../tips.rst:266 483cbd21e61841d983e2ecc8bc3006bc
+msgid ""
+"GitHub Pages will display the custom 404 page described above, as noted "
+"in the relevant `GitHub docs "
+"`_."
+msgstr ""
+"如果按前述进行配置,GitHub Pages是能够正确显示自定义的404页面的,相关内容在 "
+"`GitHub的文档中 `_ 也有提到。"
+
+#: ../../tips.rst:270 6b54e9c354f34e1f9a5a3f50d96b98c3
+msgid "Update your site on each commit"
+msgstr "在每次commit后都更新站点"
+
+#: ../../tips.rst:272 2e83c0c761c94f35ae3056634d8f1552
+msgid ""
+"To automatically update your Pelican site on each commit, you can create "
+"a post-commit hook. For example, you can add the following to "
+"``.git/hooks/post-commit``::"
+msgstr ""
+"要想在每次commit后自动更新Pelican站点,你可以创建一个post-commit钩子。例如,"
+"可以将下面的内容保存为 ``.git/hooks/post-commit`` :"
+
+#: ../../tips.rst:279 528589366e634f15bb0a702969715286
+msgid "Copy static files to the root of your site"
+msgstr "将静态文件拷贝到站点根目录"
+
+#: ../../tips.rst:281 dc4267653ef04722a0583915c05b6c88
+msgid ""
+"To use a `custom domain `_ with GitHub Pages, you need to put the "
+"domain of your site (e.g., ``blog.example.com``) inside a ``CNAME`` file "
+"at the root of your site. To do this, create the ``content/extra/`` "
+"directory and add a ``CNAME`` file to it. Then use the ``STATIC_PATHS`` "
+"setting to tell Pelican to copy this file to your output directory. For "
+"example::"
+msgstr ""
+"要将 `自定义域名 `_ 与GitHub Pages一起使用,需要将站点的域名(例如 ``blog.example.com`` "
+")添加到站点根目录的 ``CNAME`` 文件中。为此,请创建 ``content/extra/`` 目录,并在里面添加一个 ``CNAME`` "
+"文件。然后使用Pelican的 ``STATIC_PATHS`` 来告诉Pelican将此文件复制到输出目录:"
+
+#: ../../tips.rst:292 5fcdc283f55f4d8ca121cb6438c67a36
+msgid "Note: use forward slashes, ``/``, even on Windows."
+msgstr "请注意:务必使用正斜杠 ``/`` ,在Windows上也是。"
+
+#: ../../tips.rst:294 326a40a1536c462ea4974ce4b560f54c
+msgid ""
+"You can also use the ``EXTRA_PATH_METADATA`` mechanism to place a "
+"``favicon.ico`` or ``robots.txt`` at the root of any site."
+msgstr ""
+"利用 ``EXTRA_PATH_METADATA`` 机制,你可以将 ``favicon.ico`` 或 ``robots.txt`` "
+"也拷贝到站点的根目录下。"
+
+#: ../../tips.rst:298 4e589caa6f17438aae1d1a12819c6ef2
+msgid "How to add YouTube or Vimeo Videos"
+msgstr "如何添加YouTube或Vimeo视频"
+
+#: ../../tips.rst:300 5f60f033a7084739af5ef0dce5b91197
+msgid ""
+"The easiest way is to paste the embed code of the video from these sites "
+"directly into your source content."
+msgstr ""
+"最简单的方法是将这些网站的视频嵌入代码直接粘贴到您的源内容文件中。"
+
+#: ../../tips.rst:303 5446d02bebc241e88cc30b484799696c
+msgid ""
+"Alternatively, you can also use Pelican plugins like ``liquid_tags``, "
+"``pelican_youtube``, or ``pelican_vimeo`` to embed videos in your "
+"content."
+msgstr ""
+"或者,您还可以使用例如 ``liquid_tags`` 、``pelican_youtube`` 或 ``pelican_vimeo`` "
+"等Pelican插件将视频嵌入。"
+
+#: ../../tips.rst:306 c871fab4a3424b0dba84c1af24f6405f
+msgid ""
+"Moreover, markup languages like reST and Markdown have plugins that let "
+"you embed videos in the markup. You can use `reST video directive "
+"`_ for reST or `mdx_video plugin "
+"`_ for Markdown."
+msgstr ""
+"此外,像reST和 Markdown这样的标记语言都有对应插件可以让你在其中嵌入视频。"
+"可以使用 `reST的视频指令 `_ 或者 "
+"`Markdown的mdx_video插件 `_ 。"
+
+#: ../../tips.rst:313 569b7609cb9d412e942001da7c4a704c
+msgid "Develop Locally Using SSL"
+msgstr "在本地使用SSL进行开发"
+
+#: ../../tips.rst:315 e66f6f1cacc4466682461d251aedb929
+msgid "Here's how you can set up your local pelican server to support SSL."
+msgstr "以下描述了如何在本地Pelican服务器上配置SSL。"
+
+#: ../../tips.rst:317 138c34c1b6804246b79fda266a1fd937
+msgid ""
+"First, create a self-signed certificate and key using ``openssl`` (this "
+"creates ``cert.pem`` and ``key.pem``)::"
+msgstr ""
+"首先,通过 ``openssl`` 创建自签名的证书和密钥,这会生成 ``cert.pem`` 和 "
+"``key.pem`` 文件:"
+
+#: ../../tips.rst:321 ac189182bc694bcaa94cd935311f4492
+msgid ""
+"And use this command to launch the server (the server starts within your "
+"``output`` directory)::"
+msgstr ""
+"接着使用下面的命令来开启服务器(此服务器会在 ``output`` 目录下开启):"
+
+#: ../../tips.rst:325 88a33744d69f4f5bbc4a43024c43d3a0
+msgid "If you are using ``develop-server.sh``, add this to the top::"
+msgstr "如果你使用的是 ``develop-server.sh`` 脚本,在脚本的开头添加:"
+
+#: ../../tips.rst:330 9a783977fe814657b8590185af281b1e
+msgid "and modify the ``pelican.server`` line as follows::"
+msgstr "然后修改按照下述修改 ``pelican.server`` 一行:"
+
+#~ msgid ""
+#~ "To publish a Pelican site in the"
+#~ " form of User Pages, you need "
+#~ "to *push* the content of the "
+#~ "``output`` dir generated by Pelican to"
+#~ " the ``master`` branch of your "
+#~ "``.github.io`` repository on GitHub."
+#~ msgstr ""
+
+#~ msgid ""
+#~ "The ``git push`` command pushes the "
+#~ "local ``gh-pages`` branch (freshly "
+#~ "updated by the ``ghp-import`` command)"
+#~ " to the ``elemoine.github.io`` repository's "
+#~ "``master`` branch on GitHub."
+#~ msgstr ""
+
+#~ msgid ""
+#~ "Now you can push the whole project"
+#~ " ``.github.io`` to the master "
+#~ "branch of your GitHub repository::"
+#~ msgstr ""
+
+#~ msgid ""
+#~ "Pelican-powered sites can be published"
+#~ " to GitHub Pages via a `custom "
+#~ "workflow "
+#~ "`_."
+#~ " To use it:"
+#~ msgstr ""
+
+#~ msgid ""
+#~ "You may want to replace the "
+#~ "``@master`` with the ID of a "
+#~ "specific commit in this repo in "
+#~ "order to pin the version of the"
+#~ " reusable workflow that you're using: "
+#~ "``uses: "
+#~ "getpelican/pelican/.github/workflows/github_pages.yml@``."
+#~ " If you do this you might want"
+#~ " to get Dependabot to send you "
+#~ "automated pull requests to update that"
+#~ " commit ID whenever new versions of"
+#~ " this workflow are published, like "
+#~ "so:"
+#~ msgstr ""
From 44db258f59d1029210cd4d9113aad9feea29218d Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Mon, 16 Sep 2024 15:11:14 +0200
Subject: [PATCH 38/52] Adjust list of Git-ignored files
---
.gitignore | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/.gitignore b/.gitignore
index a3d27ca8..6ea22c9c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,7 +4,7 @@
*.pyc
.DS_Store
docs/_build
-docs/fr/_build
+docs/*/_build
build
dist
tags
@@ -19,9 +19,11 @@ samples/output
.pdm-python
.vale
.venv
+**/LC_MESSAGES/*.mo
# direnv
.envrc
-# pycharm
+# IDE cruft
.idea
+.vscode
From 9e8af627b528e04d84335df731872b108ad18c82 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Mon, 16 Sep 2024 15:16:43 +0200
Subject: [PATCH 39/52] Prepare release
---
RELEASE.md | 12 ++++++++++++
1 file changed, 12 insertions(+)
create mode 100644 RELEASE.md
diff --git a/RELEASE.md b/RELEASE.md
new file mode 100644
index 00000000..9f31782f
--- /dev/null
+++ b/RELEASE.md
@@ -0,0 +1,12 @@
+Release type: minor
+
+- Add setting to specify summary via paragraph count
+- Add new status to skip generation of a post
+- Add setting to append ``ref`` parameter to links in feeds
+- Configure logging handler via ``--log-handler`` CLI option
+- Resolve intra-site links in summaries
+- Warn when files are not processed due to disabled readers
+- Add Medium post importer
+- Improve GitHub Pages workflow
+- Improve code test coverage
+- Translate documentation into Simplified Chinese
From a5db130e1d3a76a27cd8387ffb47a5e24821eea5 Mon Sep 17 00:00:00 2001
From: botpub <52496925+botpub@users.noreply.github.com>
Date: Mon, 16 Sep 2024 13:23:38 +0000
Subject: [PATCH 40/52] Release Pelican 4.10.0
---
RELEASE.md | 12 ------------
docs/changelog.rst | 14 ++++++++++++++
pyproject.toml | 2 +-
3 files changed, 15 insertions(+), 13 deletions(-)
delete mode 100644 RELEASE.md
diff --git a/RELEASE.md b/RELEASE.md
deleted file mode 100644
index 9f31782f..00000000
--- a/RELEASE.md
+++ /dev/null
@@ -1,12 +0,0 @@
-Release type: minor
-
-- Add setting to specify summary via paragraph count
-- Add new status to skip generation of a post
-- Add setting to append ``ref`` parameter to links in feeds
-- Configure logging handler via ``--log-handler`` CLI option
-- Resolve intra-site links in summaries
-- Warn when files are not processed due to disabled readers
-- Add Medium post importer
-- Improve GitHub Pages workflow
-- Improve code test coverage
-- Translate documentation into Simplified Chinese
diff --git a/docs/changelog.rst b/docs/changelog.rst
index 5ef19b17..61674564 100644
--- a/docs/changelog.rst
+++ b/docs/changelog.rst
@@ -1,6 +1,20 @@
Release history
###############
+4.10.0 - 2024-09-16
+===================
+
+- Add setting to specify summary via paragraph count
+- Add new status to skip generation of a post
+- Add setting to append ``ref`` parameter to links in feeds
+- Configure logging handler via ``--log-handler`` CLI option
+- Resolve intra-site links in summaries
+- Warn when files are not processed due to disabled readers
+- Add Medium post importer
+- Improve GitHub Pages workflow
+- Improve code test coverage
+- Translate documentation into Simplified Chinese
+
4.9.1 - 2023-11-15
==================
diff --git a/pyproject.toml b/pyproject.toml
index 1a2e1474..2233ab62 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -2,7 +2,7 @@
name = "pelican"
authors = [{ name = "Justin Mayer", email = "authors@getpelican.com" }]
description = "Static site generator supporting Markdown and reStructuredText"
-version = "4.9.1"
+version = "4.10.0"
license = { text = "AGPLv3" }
readme = "README.rst"
keywords = ["static site generator", "static sites", "ssg"]
From 86bf9230b40c47f45aa30141ceca46286b5f0480 Mon Sep 17 00:00:00 2001
From: Lioman
Date: Thu, 19 Sep 2024 14:25:01 +0200
Subject: [PATCH 41/52] test: fix build test
the regex, searching for the builded files was not stable to changes for two digit versions.
fixes: Build test failures in GitHub CI workflow #3393
---
pelican/tests/build_test/test_build_files.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pelican/tests/build_test/test_build_files.py b/pelican/tests/build_test/test_build_files.py
index c80253db..8e295f32 100644
--- a/pelican/tests/build_test/test_build_files.py
+++ b/pelican/tests/build_test/test_build_files.py
@@ -61,6 +61,6 @@ def test_sdist_contents(pytestconfig, expected_file):
filtered_values = [
path
for path in files_list
- if match(rf"^pelican-\d\.\d\.\d/{expected_file}{dir_matcher}$", path)
+ if match(rf"^pelican-\d+\.\d+\.\d+/{expected_file}{dir_matcher}$", path)
]
assert len(filtered_values) > 0
From 84db21c724143e21673e266d98857c4235d1499a Mon Sep 17 00:00:00 2001
From: Lioman
Date: Fri, 20 Sep 2024 14:46:29 +0200
Subject: [PATCH 42/52] Match actual version instead of regex in `build` CI job
(#3396)
---
pelican/tests/build_test/test_build_files.py | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/pelican/tests/build_test/test_build_files.py b/pelican/tests/build_test/test_build_files.py
index 8e295f32..c59d9235 100644
--- a/pelican/tests/build_test/test_build_files.py
+++ b/pelican/tests/build_test/test_build_files.py
@@ -1,3 +1,4 @@
+import importlib.metadata
import tarfile
from pathlib import Path
from re import match
@@ -5,6 +6,8 @@ from zipfile import ZipFile
import pytest
+version = importlib.metadata.version("pelican")
+
@pytest.mark.skipif(
"not config.getoption('--check-build')",
@@ -16,7 +19,7 @@ def test_wheel_contents(pytestconfig):
that everything that is needed is included in the final build
"""
dist_folder = pytestconfig.getoption("--check-build")
- wheels = Path(dist_folder).rglob("*.whl")
+ wheels = Path(dist_folder).rglob(f"pelican-{version}-py3-none-any.whl")
for wheel_file in wheels:
files_list = ZipFile(wheel_file).namelist()
# Check if theme files are copied to wheel
@@ -52,7 +55,7 @@ def test_sdist_contents(pytestconfig, expected_file):
that everything that is needed is included in the final build.
"""
dist_folder = pytestconfig.getoption("--check-build")
- sdist_files = Path(dist_folder).rglob("*.tar.gz")
+ sdist_files = Path(dist_folder).rglob(f"pelican-{version}.tar.gz")
for dist in sdist_files:
files_list = tarfile.open(dist, "r:gz").getnames()
dir_matcher = ""
@@ -61,6 +64,6 @@ def test_sdist_contents(pytestconfig, expected_file):
filtered_values = [
path
for path in files_list
- if match(rf"^pelican-\d+\.\d+\.\d+/{expected_file}{dir_matcher}$", path)
+ if match(rf"^pelican-{version}/{expected_file}{dir_matcher}$", path)
]
assert len(filtered_values) > 0
From 6c6b940ffc80120e0334166ad03061eaf406aae9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Cl=C3=A9ment=20Pit-Claudel?=
Date: Fri, 20 Sep 2024 18:49:23 +0200
Subject: [PATCH 43/52] Don't store a RichHandler object in the argparse
namespace (#3394)
---
pelican/__init__.py | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/pelican/__init__.py b/pelican/__init__.py
index 96849bae..89a63e84 100644
--- a/pelican/__init__.py
+++ b/pelican/__init__.py
@@ -310,6 +310,9 @@ class ParseOverrides(argparse.Action):
setattr(namespace, self.dest, overrides)
+LOG_HANDLERS = {"plain": None, "rich": DEFAULT_LOG_HANDLER}
+
+
def parse_arguments(argv=None):
parser = argparse.ArgumentParser(
description="A tool to generate a static blog, "
@@ -448,7 +451,6 @@ def parse_arguments(argv=None):
),
)
- LOG_HANDLERS = {"plain": None, "rich": DEFAULT_LOG_HANDLER}
parser.add_argument(
"--log-handler",
default="rich",
@@ -513,8 +515,6 @@ def parse_arguments(argv=None):
if args.bind is not None and not args.listen:
logger.warning("--bind without --listen has no effect")
- args.log_handler = LOG_HANDLERS[args.log_handler]
-
return args
@@ -637,7 +637,7 @@ def main(argv=None):
level=args.verbosity,
fatal=args.fatal,
name=__name__,
- handler=args.log_handler,
+ handler=LOG_HANDLERS[args.log_handler],
logs_dedup_min_level=logs_dedup_min_level,
)
From 08283b491537550043dcc869ee1d5b13d89d26af Mon Sep 17 00:00:00 2001
From: Frederik Elwert
Date: Sat, 28 Sep 2024 18:55:22 +0200
Subject: [PATCH 44/52] Fix symbolic link handling in `pelican-themes -s/-c`
(#3392)
---
pelican/tools/pelican_themes.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/pelican/tools/pelican_themes.py b/pelican/tools/pelican_themes.py
index fa59b8fd..4d8cee2d 100755
--- a/pelican/tools/pelican_themes.py
+++ b/pelican/tools/pelican_themes.py
@@ -249,6 +249,7 @@ def install(path, v=False, u=False):
def symlink(path, v=False):
"""Symbolically link a theme"""
+ path = os.path.realpath(path)
if not os.path.exists(path):
err(path + " : no such file or directory")
elif not os.path.isdir(path):
@@ -269,7 +270,7 @@ def symlink(path, v=False):
def is_broken_link(path):
"""Returns True if the path given as is a broken symlink"""
- path = os.readlink(path)
+ path = os.path.realpath(path)
return not os.path.exists(path)
From fe45094545c98f6777e684ebe3134ccea2df01fb Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Sat, 28 Sep 2024 18:59:03 +0200
Subject: [PATCH 45/52] Prepare release
---
RELEASE.md | 4 ++++
1 file changed, 4 insertions(+)
create mode 100644 RELEASE.md
diff --git a/RELEASE.md b/RELEASE.md
new file mode 100644
index 00000000..94a83dd7
--- /dev/null
+++ b/RELEASE.md
@@ -0,0 +1,4 @@
+Release type: patch
+
+- Fix error when running ``pelican -r -l``
+- Fix symlink handling in ``pelican-themes``
From b86383fb28a160eeaf3e13cbf99469a0ed4cfcb2 Mon Sep 17 00:00:00 2001
From: botpub <52496925+botpub@users.noreply.github.com>
Date: Sat, 28 Sep 2024 17:02:04 +0000
Subject: [PATCH 46/52] Release Pelican 4.10.1
---
RELEASE.md | 4 ----
docs/changelog.rst | 6 ++++++
pyproject.toml | 2 +-
3 files changed, 7 insertions(+), 5 deletions(-)
delete mode 100644 RELEASE.md
diff --git a/RELEASE.md b/RELEASE.md
deleted file mode 100644
index 94a83dd7..00000000
--- a/RELEASE.md
+++ /dev/null
@@ -1,4 +0,0 @@
-Release type: patch
-
-- Fix error when running ``pelican -r -l``
-- Fix symlink handling in ``pelican-themes``
diff --git a/docs/changelog.rst b/docs/changelog.rst
index 61674564..cfc290df 100644
--- a/docs/changelog.rst
+++ b/docs/changelog.rst
@@ -1,6 +1,12 @@
Release history
###############
+4.10.1 - 2024-09-28
+===================
+
+- Fix error when running ``pelican -r -l``
+- Fix symlink handling in ``pelican-themes``
+
4.10.0 - 2024-09-16
===================
diff --git a/pyproject.toml b/pyproject.toml
index 2233ab62..0fce25ca 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -2,7 +2,7 @@
name = "pelican"
authors = [{ name = "Justin Mayer", email = "authors@getpelican.com" }]
description = "Static site generator supporting Markdown and reStructuredText"
-version = "4.10.0"
+version = "4.10.1"
license = { text = "AGPLv3" }
readme = "README.rst"
keywords = ["static site generator", "static sites", "ssg"]
From 478012e0d0bd8431d90ccac2802210778a638cd9 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Wed, 2 Oct 2024 19:08:26 +0200
Subject: [PATCH 47/52] Clarify `_include_path()` parameter docstring
---
pelican/generators.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pelican/generators.py b/pelican/generators.py
index 6b44d79e..207c9296 100644
--- a/pelican/generators.py
+++ b/pelican/generators.py
@@ -138,7 +138,7 @@ class Generator:
def _include_path(self, path, extensions=None):
"""Inclusion logic for .get_files(), returns True/False
- :param path: the path which might be including
+ :param path: potential path to include (relative to content root)
:param extensions: the list of allowed extensions, or False if all
extensions are allowed
"""
From f5dc4d4b96c0b21079dc4f60e97b241f211885bf Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Fri, 4 Oct 2024 15:04:13 +0200
Subject: [PATCH 48/52] Disable blank GitHub issues
Existing issue template categories should cover most any case.
---
.github/ISSUE_TEMPLATE/config.yml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml
index 9e240bd9..a07de4ab 100644
--- a/.github/ISSUE_TEMPLATE/config.yml
+++ b/.github/ISSUE_TEMPLATE/config.yml
@@ -1,6 +1,6 @@
---
# Ref: https://help.github.com/en/github/building-a-strong-community/configuring-issue-templates-for-your-repository#configuring-the-template-chooser
-blank_issues_enabled: true
+blank_issues_enabled: false
contact_links:
- name: '💬 Pelican IRC Channel'
url: https://web.libera.chat/?#pelican
From b02abf022009eb2ca31977b2908c42b5144f9743 Mon Sep 17 00:00:00 2001
From: Justin Mayer
Date: Fri, 4 Oct 2024 15:06:11 +0200
Subject: [PATCH 49/52] Improve GitHub issue templates
---
.github/ISSUE_TEMPLATE/---bug-report.md | 8 ++++++--
.github/ISSUE_TEMPLATE/---everything-else.md | 7 ++++++-
2 files changed, 12 insertions(+), 3 deletions(-)
diff --git a/.github/ISSUE_TEMPLATE/---bug-report.md b/.github/ISSUE_TEMPLATE/---bug-report.md
index c0f9dec6..6825b61c 100644
--- a/.github/ISSUE_TEMPLATE/---bug-report.md
+++ b/.github/ISSUE_TEMPLATE/---bug-report.md
@@ -17,11 +17,15 @@ assignees: ''
- [ ] I have read the [Filing Issues](https://docs.getpelican.com/en/latest/contribute.html#filing-issues) and subsequent “How to Get Help” sections of the documentation.
+- [ ] I can reproduce this problem with stock/default settings file, theme, and sample content (as described in above “How to Get Help” sections of the documentation).
- [ ] I have searched the [issues](https://github.com/getpelican/pelican/issues?q=is%3Aissue) (including closed ones) and believe that this is not a duplicate.
- **OS version and name**:
diff --git a/.github/ISSUE_TEMPLATE/---everything-else.md b/.github/ISSUE_TEMPLATE/---everything-else.md
index fd2a58ae..23a3f7bd 100644
--- a/.github/ISSUE_TEMPLATE/---everything-else.md
+++ b/.github/ISSUE_TEMPLATE/---everything-else.md
@@ -8,7 +8,11 @@ assignees: ''
---
- [ ] I have searched the [issues](https://github.com/getpelican/pelican/issues?q=is%3Aissue) (including closed ones) and believe that this is not a duplicate.
- [ ] I have searched the [documentation](https://docs.getpelican.com/) and believe that my question is not covered.
+- [ ] I have carefully read the [How to Get Help](https://docs.getpelican.com/en/latest/contribute.html#how-to-get-help) section of the documentation.
## Issue
From 92050d90bc99f65dfdcd2297d8223228a0d08367 Mon Sep 17 00:00:00 2001
From: Frederik Elwert
Date: Thu, 10 Oct 2024 14:35:07 +0200
Subject: [PATCH 50/52] Add FAQ regarding theme overrides
Currently, the documentation refers to creating new themes a lot.
It is much less apparent how one can customize an existing theme by
overriding individual templates or adding new ones. This commit adds
an FAQ for this, and also mentions the mechanism in the FAQ on custom
templates.
---
docs/faq.rst | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)
diff --git a/docs/faq.rst b/docs/faq.rst
index bbf058cd..8ae3af29 100644
--- a/docs/faq.rst
+++ b/docs/faq.rst
@@ -64,6 +64,19 @@ How do I create my own theme?
Please refer to :ref:`theming-pelican`.
+Can I override individual templates without forking the whole theme?
+====================================================================
+
+Yes, you can override existing templates of the theme that you are using, or
+add new templates, via the ``THEME_TEMPLATES_OVERRIDES`` variable. For example,
+to override the page template, you can define the location for your templates
+like this::
+
+ THEME_TEMPLATES_OVERRIDES = ["templates"]
+
+You can then define a custom template in ``templates/page.html``.
+See :ref:`settings/themes` for details.
+
I want to use Markdown, but I got an error.
===========================================
@@ -122,7 +135,8 @@ For content in Markdown format::
Template: template_name
Then just make sure your theme contains the relevant template file (e.g.
-``template_name.html``).
+``template_name.html``). If you just want to add a new custom template to an
+existing theme, you can also provide it in a directory specified by ``THEME_TEMPLATES_OVERRIDES`` (see :ref:`settings/themes`).
How can I override the generated URL of a specific page or article?
===================================================================
From 0da2530d9b0de8c8a3c9757f8e9d6d520d837fc2 Mon Sep 17 00:00:00 2001
From: Noel Miller <4983138+noelmiller@users.noreply.github.com>
Date: Tue, 22 Oct 2024 11:59:19 -0500
Subject: [PATCH 51/52] De-couple build workflow from GitHub Pages publication
(#3404)
---
.github/workflows/github_pages.yml | 14 +++++++---
docs/tips.rst | 45 ++++++++++++++++++++++++++++++
2 files changed, 55 insertions(+), 4 deletions(-)
diff --git a/.github/workflows/github_pages.yml b/.github/workflows/github_pages.yml
index 48ebb2d0..9c279ab1 100644
--- a/.github/workflows/github_pages.yml
+++ b/.github/workflows/github_pages.yml
@@ -1,4 +1,4 @@
-# Workflow for publishing to GitHub Pages.
+# Workflow for building the site and (optionally) publishing it to GitHub Pages.
name: Deploy to GitHub Pages
on:
workflow_call:
@@ -37,13 +37,15 @@ on:
default: ""
description: "The domain to be prepended to feed URLs (Pelican's FEED_DOMAIN setting). If not passed this will default to the URL of your GitHub Pages site, which is correct in most cases."
type: string
+ deploy:
+ required: false
+ default: true
+ description: "Whether to deploy the site. If true then build the site and deploy it. If false then just test that the site builds successfully but don't deploy anything."
+ type: boolean
permissions:
contents: read
pages: write
id-token: write
-concurrency:
- group: "pages"
- cancel-in-progress: false
jobs:
build:
runs-on: ubuntu-latest
@@ -88,6 +90,10 @@ jobs:
with:
path: ${{ inputs.output-path }}
deploy:
+ concurrency:
+ group: "pages"
+ cancel-in-progress: false
+ if: ${{ inputs.deploy }}
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
diff --git a/docs/tips.rst b/docs/tips.rst
index e5574c7c..4df20ae3 100644
--- a/docs/tips.rst
+++ b/docs/tips.rst
@@ -246,7 +246,52 @@ Here's the complete list of workflow inputs:
| | | your GitHub Pages site, which is correct | | |
| | | in most cases. | | |
+------------------+----------+--------------------------------------------+--------+---------------+
+| ``deploy`` | No | This is used to determine whether you will | bool | ``true`` |
+| | | deploy the site or not to GitHub Pages. | | |
+| | | This is most useful if you want to test a | | |
+| | | change to your website in a pull request | | |
+| | | before deploying those change. | | |
++------------------+----------+--------------------------------------------+--------+---------------+
+Testing Your Build in a GitHub Pull Request
+"""""""""""""""""""""""""""""""""""""""""""
+
+If you want to test your build in a pull request before deploying to GitHub, your workflow might look something like this:
+
+.. code-block:: yaml
+
+ name: Build and Deploy Site
+ on:
+ push:
+ branches: ["main"]
+ pull_request:
+ branches: ["main"]
+ workflow_dispatch:
+ inputs:
+ deploy:
+ required: false
+ default: true
+ description: "Whether to deploy the site. If checked, then build the site and deploy it. If not checked, then just test that the site builds successfully but don't deploy anything."
+ type: boolean
+ jobs:
+ deploy:
+ uses: "getpelican/pelican/.github/workflows/github_pages.yml@main"
+ permissions:
+ id-token: write
+ contents: read
+ pages: write
+ with:
+ settings: "publishconf.py"
+ requirements: "-r requirements.txt"
+ deploy: ${{ (github.event_name == 'workflow_dispatch' && inputs.deploy == true) || (github.event_name == 'push' && github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch) }}
+
+The ``on`` section of the workflow defines the events that will trigger the workflow. In this example, the workflow will run on pushes to the main branch, pull requests to the main branch, and manual runs of the workflow.
+
+``workflow_dispatch`` defines the deploy boolean to be true by default. This means that if you run the workflow manually, it will deploy the site.
+
+The ``deploy`` input for the job is using a set of standard GitHub workflow variables to control when ``deploy`` will either be true or false (you can customize this to your needs).
+
+In this example, the ``deploy`` will be true if the event is a push to the main branch (or merging into main from a PR) or a manual run of the workflow. If the event is a pull request, the ``deploy`` will be false and it will only build an artifact for the site.
"Insecure content" warnings from browsers
"""""""""""""""""""""""""""""""""""""""""
From 075542721cf3ab893526ddda3355821d0ac3cac3 Mon Sep 17 00:00:00 2001
From: boxydog
Date: Sun, 3 Nov 2024 13:28:44 -0600
Subject: [PATCH 52/52] pre-commit autoupdate and fix new issues pointed out by
ruff
---
.pre-commit-config.yaml | 6 +++---
pelican/tools/pelican_quickstart.py | 6 +++---
pelican/tools/pelican_themes.py | 1 -
pyproject.toml | 2 +-
4 files changed, 7 insertions(+), 8 deletions(-)
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index 9ae674ab..716ddd89 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -2,7 +2,7 @@
# See https://pre-commit.com/hooks.html for info on hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
- rev: v4.6.0
+ rev: v5.0.0
hooks:
- id: check-added-large-files
- id: check-ast
@@ -16,14 +16,14 @@ repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# ruff version should match the one in pyproject.toml
- rev: v0.4.10
+ rev: v0.7.2
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
- id: ruff-format
- repo: https://github.com/rtts/djhtml
- rev: '3.0.6'
+ rev: '3.0.7'
hooks:
- id: djhtml
- id: djcss
diff --git a/pelican/tools/pelican_quickstart.py b/pelican/tools/pelican_quickstart.py
index e278e3bc..77131a52 100755
--- a/pelican/tools/pelican_quickstart.py
+++ b/pelican/tools/pelican_quickstart.py
@@ -87,7 +87,7 @@ _DEFAULT_PATH = _DEFAULT_PATH_TYPE(os.curdir)
def ask(question, answer=str, default=None, length=None):
- if answer == str:
+ if answer is str:
r = ""
while True:
if default:
@@ -110,7 +110,7 @@ def ask(question, answer=str, default=None, length=None):
return r
- elif answer == bool:
+ elif answer is bool:
r = None
while True:
if default is True:
@@ -134,7 +134,7 @@ def ask(question, answer=str, default=None, length=None):
else:
print("You must answer 'yes' or 'no'")
return r
- elif answer == int:
+ elif answer is int:
r = None
while True:
if default:
diff --git a/pelican/tools/pelican_themes.py b/pelican/tools/pelican_themes.py
index 4d8cee2d..adf86dc0 100755
--- a/pelican/tools/pelican_themes.py
+++ b/pelican/tools/pelican_themes.py
@@ -23,7 +23,6 @@ except ImportError:
)
-global _THEMES_PATH
_THEMES_PATH = os.path.join(
os.path.dirname(os.path.abspath(pelican.__file__)), "themes"
)
diff --git a/pyproject.toml b/pyproject.toml
index 0fce25ca..f3629015 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -97,7 +97,7 @@ dev = [
"tox>=4.11.3",
"invoke>=2.2.0",
# ruff version should match the one in .pre-commit-config.yaml
- "ruff==0.4.10",
+ "ruff==0.7.2",
"tomli>=2.0.1; python_version < \"3.11\"",
]