Python theme packaging
This MR should make the pelican theme accessible via pypi.org , where many python packages are hosted already
closes #82
Codecov Report
Merging #97 into master will not change coverage. The diff coverage is
n/a.
@@ Coverage Diff @@
## master #97 +/- ##
=======================================
Coverage 97.52% 97.52%
=======================================
Files 21 21
Lines 4205 4205
Branches 40 40
=======================================
Hits 4101 4101
Misses 104 104
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing dataPowered by Codecov. Last update 07a027f...fae9ce2. Read the comment docs.
This seems to be copied from my seafoam Pelican theme. You'll want to change it a little more to be specific to your project requirements.
Also, you may want to check out the project's __init__.py file, which has a short function:
# seafoam/__init__.py
from pathlib import Path
def get_path():
"""
Shortcut for users whose theme is not next to their pelicanconf.py.
Returns:
str: filepath to folder containing theme
"""
# Theme directory is defined as our parent directory
return str(Path(__file__).resolve().parent)
This way, in your pelicanconf.py file (for your actual site), you can specifiy the theme like this:
# pelicanconf.py for your generated site
import seafoam
THEME = seafoam.get_path()