-
-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Road to Mkdocs >= 1.4: plugin's configuration (#195)
- Loading branch information
Showing
4 changed files
with
55 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#! python3 # noqa: E265 | ||
|
||
# ############################################################################ | ||
# ########## Libraries ############# | ||
# ################################## | ||
|
||
|
||
# 3rd party | ||
from mkdocs.config import config_options | ||
from mkdocs.config.base import Config | ||
|
||
|
||
# ############################################################################ | ||
# ########## Classes ############### | ||
# ################################## | ||
class RssPluginConfig(Config): | ||
"""Configuration for RSS plugin for Mkdocs.""" | ||
|
||
abstract_chars_count = config_options.Type(int, default=160) | ||
abstract_delimiter = config_options.Type(str, default="<!-- more -->") | ||
categories = config_options.Optional( | ||
config_options.ListOfItems(config_options.Type(str)) | ||
) | ||
comments_path = config_options.Optional(config_options.Type(str)) | ||
date_from_meta = config_options.Optional(config_options.Type(dict)) | ||
enabled = config_options.Type(bool, default=True) | ||
feed_ttl = config_options.Type(int, default=1440) | ||
image = config_options.Optional(config_options.Type(str)) | ||
length = config_options.Type(int, default=20) | ||
match_path = config_options.Type(str, default=".*") | ||
pretty_print = config_options.Type(bool, default=False) | ||
url_parameters = config_options.Optional(config_options.Type(dict)) | ||
use_git = config_options.Type(bool, default=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters