nefelibata package¶
Subpackages¶
Submodules¶
nefelibata.console module¶
Nefelibata weblog engine.
- Usage:
nb init [ROOT_DIR] [–loglevel=INFO] nb new POST [ROOT_DIR] [–loglevel=INFO] nb build [ROOT_DIR] [-f] [-s POST_DIR] [–no-collect] [–loglevel=INFO] nb preview [-p PORT] [ROOT_DIR] [–loglevel=INFO] nb publish [ROOT_DIR] [-f] [-s POST_DIR] [–loglevel=INFO]
- Actions:
init Create a new weblog skeleton. new Create a new post. build Build weblog from Markdown and social media interactions. preview Run SimpleHTTPServer. publish Publish weblog to configured locations and announce new posts.
- Options:
-h –help Show this screen. –version Show version. -p PORT Port to run the web server for preview. [default: 8000] -f –force Force build/publishing of up-to-date resources. -s POST_DIR Build/publish a single post by specifying its directory –no-collect Do not collect replies when building. –loglevel=LEVEL Level for logging. [default: INFO]
Released under the MIT license. (c) 2013-2020 Beto Dealmeida <roberto@dealmeida.net>
nefelibata.post module¶
-
class
nefelibata.post.Post(file_path: pathlib.Path)[source]¶ Bases:
object-
property
date¶
-
property
summary¶
-
property
title¶
-
property
up_to_date¶
-
property
url¶
-
property
-
nefelibata.post.get_posts(root: pathlib.Path) → List[nefelibata.post.Post][source]¶ Return list of posts for a given root directory.
nefelibata.utils module¶
-
nefelibata.utils.find_directory(cwd: pathlib.Path) → pathlib.Path[source]¶ Find root of blog, starting from cwd.
The function will traverse up trying to find a configuration file.
-
nefelibata.utils.get_config(root: pathlib.Path) → Dict[str, Any][source]¶ Return the configuration file for a weblog.
-
nefelibata.utils.json_storage(file_path: pathlib.Path) → Iterator[Dict[str, Any]][source]¶ Open a file and load it as JSON. Save back if modified.
-
nefelibata.utils.modify_html(file_path: pathlib.Path) → Iterator[bs4.BeautifulSoup][source]¶ Parse an HTML file to BeautifulSoup. Save back if modified.