cd pelican-theme
python -m unittest
- cd pelican-plugins
+ cd plugins
python -m unittest
cd doxygen
node ./node_modules/istanbul/lib/cli.js cover test/test-search.js
# open coverage/lcov-report/index.html in your browser
- cd pelican-plugins
+ cd plugins
coverage run -m unittest ; coverage html
# open htmlcov/index.html in your browser
For that, m.css provides a custom Pygments lexer that's together with
`pygments-console.css <{filename}/css.rst>`_ able to detect and highlight the
basic 4-bit color codes (8 foreground colors in either normal or bright
-version). Download the :gh:`ansilexer.py <mosra/m.css$master/pelican-plugins/m/ansilexer.py>`
+version). Download the :gh:`ansilexer.py <mosra/m.css$master/plugins/m/ansilexer.py>`
file or use it directly from your Git clone of m.css. Example usage:
.. code:: sh
- ls -C --color=always | pygmentize -l pelican-plugins/ansilexer.py:AnsiLexer -x -f html -O nowrap
+ ls -C --color=always | pygmentize -l plugins/ansilexer.py:AnsiLexer -x -f html -O nowrap
Wrap the HTML output in either :html:`<pre class="m-console">` for a block
listing or :html:`<code class="m-console">` for inline listing. The output
.. code:: html
- <pre class="m-console">CONTRIBUTING.rst CREDITS.rst <span class="g g-AnsiBrightBlue">doc</span> <span class="g g-AnsiBrightBlue">pelican-plugins</span> README.rst
- COPYING <span class="g g-AnsiBrightBlue">css</span> <span class="g g-AnsiBrightBlue">doxygen</span> <span class="g g-AnsiBrightBlue">pelican-theme</span> <span class="g g-AnsiBrightBlue">site</span></pre>
+ <pre class="m-console">CONTRIBUTING.rst CREDITS.rst <span class="g g-AnsiBrightBlue">doc</span> <span class="g g-AnsiBrightBlue">plugins</span> README.rst
+ COPYING <span class="g g-AnsiBrightBlue">css</span> <span class="g g-AnsiBrightBlue">doxygen</span> <span class="g g-AnsiBrightBlue">pelican-theme</span> <span class="g g-AnsiBrightBlue">site</span></pre>
.. raw:: html
- <pre class="m-console">CONTRIBUTING.rst CREDITS.rst <span class="g g-AnsiBrightBlue">doc</span> <span class="g g-AnsiBrightBlue">pelican-plugins</span> README.rst
- COPYING <span class="g g-AnsiBrightBlue">css</span> <span class="g g-AnsiBrightBlue">doxygen</span> <span class="g g-AnsiBrightBlue">pelican-theme</span> <span class="g g-AnsiBrightBlue">site</span></pre>
+ <pre class="m-console">CONTRIBUTING.rst CREDITS.rst <span class="g g-AnsiBrightBlue">doc</span> <span class="g g-AnsiBrightBlue">plugins</span> README.rst
+ COPYING <span class="g g-AnsiBrightBlue">css</span> <span class="g g-AnsiBrightBlue">doxygen</span> <span class="g g-AnsiBrightBlue">pelican-theme</span> <span class="g g-AnsiBrightBlue">site</span></pre>
.. note-success::
.. code:: sh
- echo "\$\$ a^2 = b^2 + c^2 \$\$" | python pelican-plugins/latex2svg.py > formula.svg
+ echo "\$\$ a^2 = b^2 + c^2 \$\$" | python plugins/latex2svg.py > formula.svg
The ``formula.svg`` file will then contain the rendered formula, which with
some minor patching (removing the XML preamble etc.) can be pasted directly
'/static/m-dark.css']
M_THEME_COLOR = '#22272e'
- PLUGIN_PATHS = ['m.css/pelican-plugins']
+ PLUGIN_PATHS = ['m.css/plugins']
PLUGINS = ['m.htmlsanity']
Here you can take advantage of the ``pelicanconf.py`` and ``publishconf.py``
and restart Pelican. Download the plugins below or
:gh:`grab the whole Git repository <mosra/m.css>`:
-- :gh:`m.htmlsanity <mosra/m.css$master/pelican-plugins/m/htmlsanity.py>`
-- :gh:`m.components <mosra/m.css$master/pelican-plugins/m/components.py>`
-- :gh:`m.images <mosra/m.css$master/pelican-plugins/m/images.py>`
-- :gh:`m.math <mosra/m.css$master/pelican-plugins/m/math.py>` (needs also :gh:`latex2svg <mosra/m.css$master/pelican-plugins/latex2svg.py>`),
- :gh:`m.code <mosra/m.css$master/pelican-plugins/m/code.py>` (needs also :gh:`ansilexer <mosra/m.css$master/pelican-plugins/ansilexer.py>`)
-- :gh:`m.plots <mosra/m.css$master/pelican-plugins/m/plots.py>`,
- :gh:`m.dot <mosra/m.css$master/pelican-plugins/m/dot.py>`
-- :gh:`m.link <mosra/m.css$master/pelican-plugins/m/link.py>`,
- :gh:`m.gh <mosra/m.css$master/pelican-plugins/m/gh.py>`,
- :gh:`m.dox <mosra/m.css$master/pelican-plugins/m/dox.py>`,
- :gh:`m.gl <mosra/m.css$master/pelican-plugins/m/gl.py>`,
- :gh:`m.vk <mosra/m.css$master/pelican-plugins/m/vk.py>`,
- :gh:`m.abbr <mosra/m.css$master/pelican-plugins/m/abbr.py>`,
- :gh:`m.filesize <mosra/m.css$master/pelican-plugins/m/filesize.py>`,
- :gh:`m.alias <mosra/m.css$master/pelican-plugins/m/alias.py>`
-- :gh:`m.metadata <mosra/m.css$master/pelican-plugins/m/metadata.py>`
+- :gh:`m.htmlsanity <mosra/m.css$master/plugins/m/htmlsanity.py>`
+- :gh:`m.components <mosra/m.css$master/plugins/m/components.py>`
+- :gh:`m.images <mosra/m.css$master/plugins/m/images.py>`
+- :gh:`m.math <mosra/m.css$master/plugins/m/math.py>` (needs also :gh:`latex2svg <mosra/m.css$master/plugins/latex2svg.py>`),
+ :gh:`m.code <mosra/m.css$master/plugins/m/code.py>` (needs also :gh:`ansilexer <mosra/m.css$master/plugins/ansilexer.py>`)
+- :gh:`m.plots <mosra/m.css$master/plugins/m/plots.py>`,
+ :gh:`m.dot <mosra/m.css$master/plugins/m/dot.py>`
+- :gh:`m.link <mosra/m.css$master/plugins/m/link.py>`,
+ :gh:`m.gh <mosra/m.css$master/plugins/m/gh.py>`,
+ :gh:`m.dox <mosra/m.css$master/plugins/m/dox.py>`,
+ :gh:`m.gl <mosra/m.css$master/plugins/m/gl.py>`,
+ :gh:`m.vk <mosra/m.css$master/plugins/m/vk.py>`,
+ :gh:`m.abbr <mosra/m.css$master/plugins/m/abbr.py>`,
+ :gh:`m.filesize <mosra/m.css$master/plugins/m/filesize.py>`,
+ :gh:`m.alias <mosra/m.css$master/plugins/m/alias.py>`
+- :gh:`m.metadata <mosra/m.css$master/plugins/m/metadata.py>`
Click on the headings below to get to know more. Note that particular plugins
can have additional dependencies besides just Pelican, see documentation of
!\e[0;34m[\e[1;37mmosra@don-perverzo \e[0;37mm.css\e[0;34m]\e[1;36m$ \e[0mls
-CONTRIBUTING.rst CREDITS.rst \e[0m\e[01;34mdoc\e[0m \e[01;34mpelican-plugins\e[0m README.rst
-COPYING \e[01;34mcss\e[0m \e[01;34mdoxygen\e[0m \e[01;34mpelican-theme\e[0m \e[01;34msite\e[0m
+CONTRIBUTING.rst CREDITS.rst \e[0m\e[01;34mdoc\e[0m \e[01;34mplugins\e[0m README.rst
+COPYING \e[01;34mcss\e[0m \e[01;34mdoxygen\e[0m \e[01;34mpelican-theme\e[0m \e[01;34msite\e[0m
from pygments.formatters import HtmlFormatter
from pygments.lexers import TextLexer, BashSessionLexer, get_lexer_by_name, find_lexer_class_for_filename
-sys.path.append(os.path.join(os.path.dirname(os.path.realpath(__file__)), '../pelican-plugins'))
+sys.path.append(os.path.join(os.path.dirname(os.path.realpath(__file__)), '../plugins'))
import dot2svg
import latex2svg
import latex2svgextra
-../../../pelican-plugins/m/test/images/tiny.png
\ No newline at end of file
+../../../plugins/m/test/images/tiny.png
\ No newline at end of file
- if [ "$WITH_THEME" == "ON" ]; then cd $TRAVIS_BUILD_DIR/pelican-theme && python -m unittest; fi
# Test plugins. Math plugin is not tested as dvisvgm on 14.04 is unusable.
- - if [ "$WITH_THEME" == "ON" ]; then cd $TRAVIS_BUILD_DIR/pelican-plugins && coverage run -m unittest && cp .coverage ../.coverage.plugins; fi
+ - if [ "$WITH_THEME" == "ON" ]; then cd $TRAVIS_BUILD_DIR/plugins && coverage run -m unittest && cp .coverage ../.coverage.plugins; fi
# Test doxygen theme. Math rendering is not tested as dvisvgm on 14.04 is
# unusable.
def run_pelican(self, settings):
implicit_settings = {
'THEME': '.',
- 'PLUGIN_PATHS': ['../pelican-plugins'],
+ 'PLUGIN_PATHS': ['../plugins'],
'PLUGINS': ['m.htmlsanity'],
'THEME_STATIC_DIR': 'static',
'M_CSS_FILES': ['https://fonts.googleapis.com/css?family=Source+Sans+Pro:400,400i,600,600i',
# This is the minimal that's required. Not even the M_THEME_COLOR
# is required.
'THEME': '.',
- 'PLUGIN_PATHS': ['../pelican-plugins'],
+ 'PLUGIN_PATHS': ['../plugins'],
'PLUGINS': ['m.htmlsanity'],
'THEME_STATIC_DIR': 'static',
'M_CSS_FILES': ['https://fonts.googleapis.com/css?family=Source+Sans+Pro:400,400i,600,600i',
<p>Inline code is here: <code class="cpp m-code"><span class="k">constexpr</span></code>. Code without a language should be
rendered as plain monospace text: <code>code</code>.</p>
<pre class="m-console">!<span class="g g-AnsiBlue">[</span><span class="g g-AnsiBrightWhite">mosra@don-perverzo </span><span class="g g-AnsiWhite">m.css</span><span class="g g-AnsiBlue">]</span><span class="g g-AnsiBrightCyan">$ </span>ls
-CONTRIBUTING.rst CREDITS.rst <span class="g g-AnsiBrightBlue">doc</span> <span class="g g-AnsiBrightBlue">pelican-plugins</span> README.rst
-COPYING <span class="g g-AnsiBrightBlue">css</span> <span class="g g-AnsiBrightBlue">doxygen</span> <span class="g g-AnsiBrightBlue">pelican-theme</span> <span class="g g-AnsiBrightBlue">site</span></pre>
+CONTRIBUTING.rst CREDITS.rst <span class="g g-AnsiBrightBlue">doc</span> <span class="g g-AnsiBrightBlue">plugins</span> README.rst
+COPYING <span class="g g-AnsiBrightBlue">css</span> <span class="g g-AnsiBrightBlue">doxygen</span> <span class="g g-AnsiBrightBlue">pelican-theme</span> <span class="g g-AnsiBrightBlue">site</span></pre>
<pre class="m-code">// this language is not highlighted</pre>
<p>Properly preserve backslashes: <code class="m-code"><span class="k">\frac</span><span class="nb">{</span>a<span class="nb">}{</span>b<span class="nb">}</span></code></p>
<p>Don't trim leading spaces in blocks:</p>
('Writing content', 'pelican/writing-content/', 'pelican/writing-content'),
('Theme', 'pelican/theme/', 'pelican/theme')])]
-M_LINKS_NAVBAR2 = [('Pelican plugins', 'plugins/', 'plugins', [
+M_LINKS_NAVBAR2 = [('Plugins', 'plugins/', 'plugins', [
('HTML sanity', 'plugins/htmlsanity/', 'plugins/htmlsanity'),
('Components', 'plugins/components/', 'plugins/components'),
('Images', 'plugins/images/', 'plugins/images'),
('', ''),
('Doxygen theme', 'doxygen/')]
-M_LINKS_FOOTER4 = [('Pelican plugins', 'plugins/'),
+M_LINKS_FOOTER4 = [('Plugins', 'plugins/'),
('HTML sanity', 'plugins/htmlsanity/'),
('Components', 'plugins/components/'),
('Images', 'plugins/images/'),
STATIC_PATHS = ['static']
EXTRA_PATH_METADATA = {'static/favicon.ico': {'path': 'favicon.ico'}}
-PLUGIN_PATHS = ['../pelican-plugins']
+PLUGIN_PATHS = ['../plugins']
PLUGINS = ['m.abbr',
'm.code',
'm.components',