:orphan: |rss_image| :ref:`<== ` **blog page - 5/6** :ref:`==> ` :ref:`Blog ` :ref:`notebook (8) ` :ref:`sphinx (13) ` .. |rss_image| image:: feed-icon-16x16.png :target: ../_downloads/rss.xml :alt: RSS ---- .. _ap-main-4: blog page - 5/6 +++++++++++++++ .. blogpostagg:: :title: Python code to generate part of sphinx documentation :date: 2015-12-12 :keywords: sphinx,extensions,runpython :categories: sphinx :rawfile: 2015/2015-12-18_runpython.rst I used the same title as a question asked on stackoverflow: `Python code to generate part of sphinx documentation, is it possible? `_. It became the following :class:`RunPythonDirective ` which does the same with more options:: ... .. blogpostagg:: :title: Local contents in Sphinx :date: 2015-12-05 :keywords: sphinx,contents :categories: sphinx :rawfile: 2015/2015-12-05_local_content.rst The Sphinx command `contents `_ adds a table of contents to a page. As contents is pretty common, on the web, it is not always easy to search for it:: ... .. blogpostagg:: :title: A few tips with Sphinx :date: 2015-10-10 :keywords: sphinx,tips,latex,bullets :categories: sphinx,latex :rawfile: 2015/2015-10-10_tips_sphinx.rst Sphinx generates many warning when it builds the documentation despite the fact the result looks good. Some cases. ... .. blogpostagg:: :title: Why do I see invered question in a notebook converted into PDF? :date: 2015-08-30 :keywords: latex, :categories: sphinx,notebook :rawfile: 2015/2015-08-30_unicode_notebook.rst The function :func:`process_notebooks ` still uses the executable `pdflatex `_ and not `xetex `_ which can handle inline unicode characters. That's why they are replaced by *¿* by function :func:`post_process_latex `. .. blogpostagg:: :title: Issue with module babel :date: 2015-08-17 :keywords: babel,sphinx,exception,issue :categories: sphinx,modules :rawfile: 2015/2015-08-17_babel13.rst I went through the following issue with the latest version of `babel `_ (2.0). It happens when I try to generate the documentation for this module. It gave me the following exception:: ... .. blogpostagg:: :title: Convert a notebook into slides :date: 2015-05-16 :keywords: script,notebook,slides,add_tag_slide :categories: notebook,automation :rawfile: 2015/2015-05-16_notebook_in_slides.rst I thought it would be easy to convert a notebook into slides. I would just have to execute `nbconvert `_. I went through two issues. The first one came from `reveal.js `_. My first tries did not work. I decided to take the version included in the module `sphinxjp.themes.revealjs `_ and I also updated the output of *nbconvert* to remove external links as much as possible. ... .. blogpostagg:: :title: Add a custom menu to the notebook :date: 2015-05-14 :keywords: script,menu :categories: notebook,automation :rawfile: 2015/2015-05-14_menu_notebook.rst The function :func:`add_notebook_menu ` add HTML and Javascript to the notebook to create links to all sections in the notebook:: ... .. blogpostagg:: :title: Create a script to read this blog :date: 2015-05-10 :keywords: script :categories: automation,blog :rawfile: 2015/2015-05-10_blog_script.rst The module now includes a function :func:`write_module_scripts ` creates a script *auto_rss_server.py* which grabs the latest blog post from this stream, runs a server and opens the default browser to read them. It uses the module `pyrsslocal `_. Here is the code to read this blog:: ... .. blogpostagg:: :title: Frequent commands and automation :date: 2015-05-06 :keywords: command line,batch files :categories: automation,setup :rawfile: 2015/2015-05-06_build_script.rst The script ``setup.py`` accepts several options such as ``install`` or ``build``. It also accepts ``unittest`` to run the unit tests or ``build_sphinx`` to build the documentation. It usually requires to have a command line windows opened as well as an editor to write programs. On Windows, the module now produces a series of scripts to automate tasks such as running the unit tests, building the documentation. They are not included in the sources anymore but the can be obtained by typing:: ... .. blogpostagg:: :title: Visualize differences between two files in a notebook :date: 2015-04-23 :keywords: diffview,difflib.js,differences :categories: javascript,notebook :rawfile: 2015/2015-04-23_diffview.rst It is now possible to visualize the differences between two files directly from a notebook: ... ---- |rss_image| :ref:`<== ` **blog page - 5/6** :ref:`==> ` :ref:`2020-08 (2) ` :ref:`2020-09 (1) ` :ref:`2021-01 (1) ` :ref:`2022-03 (1) ` :ref:`2023-05 (1) `