Skip to content

Commit

Permalink
Fix documentation issues.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ken Kundert authored and Ken Kundert committed Sep 18, 2020
1 parent 83fdb5a commit 3bb8661
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 2 deletions.
6 changes: 6 additions & 0 deletions doc/nestedtext.dump.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
nestedtext.dump
===============

.. currentmodule:: nestedtext

.. autofunction:: dump
6 changes: 6 additions & 0 deletions doc/nestedtext.load.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
nestedtext.load
===============

.. currentmodule:: nestedtext

.. autofunction:: load
6 changes: 4 additions & 2 deletions nestedtext.py
Original file line number Diff line number Diff line change
Expand Up @@ -606,14 +606,16 @@ def load(f=None, on_dup=None):
Load from a `pathlib.Path`:
.. code-block:: pycon
.. code-block:: python
>>> from pathlib import Path
>>> nt.load(Path('examples/groceries.nt'))
['Bread', 'Peanut butter', 'Jam']
Load from an open file object:
.. code-block:: pycon
.. code-block:: python
>>> with open('examples/groceries.nt') as f:
... nt.load(f)
...
Expand Down

0 comments on commit 3bb8661

Please sign in to comment.