Skip to content

Commit 17dd2b1

Browse files
committed
Show imports in docs
1 parent 21e3e3a commit 17dd2b1

File tree

7 files changed

+49
-3
lines changed

7 files changed

+49
-3
lines changed

README.md

+2
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111
[See the documentation](https://wragge.github.io/omeka_s_tools/api.html) for full details of the Omeka API Client.
1212

1313
```python
14+
from omeka_s_tools.api import OmekaAPIClient
15+
1416
omeka = OmekaAPIClient('http://timsherratt.org/collections/api')
1517
```
1618

api.ipynb

+16
Original file line numberDiff line numberDiff line change
@@ -445,6 +445,22 @@
445445
" return files"
446446
]
447447
},
448+
{
449+
"cell_type": "markdown",
450+
"metadata": {},
451+
"source": [
452+
"First import the `OmekaAPIClient` class."
453+
]
454+
},
455+
{
456+
"cell_type": "code",
457+
"execution_count": null,
458+
"metadata": {},
459+
"outputs": [],
460+
"source": [
461+
"from omeka_s_tools.api import OmekaAPIClient"
462+
]
463+
},
448464
{
449465
"cell_type": "markdown",
450466
"metadata": {},

docs/api.html

+24
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,30 @@ <h2 id="OmekaAPIClient" class="doc_header"><code>class</code> <code>OmekaAPIClie
5757

5858
<div class="cell border-box-sizing code_cell rendered">
5959

60+
</div>
61+
{% endraw %}
62+
63+
<div class="cell border-box-sizing text_cell rendered"><div class="inner_cell">
64+
<div class="text_cell_render border-box-sizing rendered_html">
65+
<p>First import the <a href="/omeka_s_tools/api.html#OmekaAPIClient"><code>OmekaAPIClient</code></a> class.</p>
66+
67+
</div>
68+
</div>
69+
</div>
70+
{% raw %}
71+
72+
<div class="cell border-box-sizing code_cell rendered">
73+
<div class="input">
74+
75+
<div class="inner_cell">
76+
<div class="input_area">
77+
<div class=" highlight hl-ipython3"><pre><span></span><span class="kn">from</span> <span class="nn">omeka_s_tools.api</span> <span class="kn">import</span> <span class="n">OmekaAPIClient</span>
78+
</pre></div>
79+
80+
</div>
81+
</div>
82+
</div>
83+
6084
</div>
6185
{% endraw %}
6286

docs/index.html

+3-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,9 @@ <h2 id="How-to-use">How to use<a class="anchor-link" href="#How-to-use"> </a></h
5656

5757
<div class="inner_cell">
5858
<div class="input_area">
59-
<div class=" highlight hl-ipython3"><pre><span></span><span class="n">omeka</span> <span class="o">=</span> <span class="n">OmekaAPIClient</span><span class="p">(</span><span class="s1">&#39;http://timsherratt.org/collections/api&#39;</span><span class="p">)</span>
59+
<div class=" highlight hl-ipython3"><pre><span></span><span class="kn">from</span> <span class="nn">omeka_s_tools.api</span> <span class="kn">import</span> <span class="n">OmekaAPIClient</span>
60+
61+
<span class="n">omeka</span> <span class="o">=</span> <span class="n">OmekaAPIClient</span><span class="p">(</span><span class="s1">&#39;http://timsherratt.org/collections/api&#39;</span><span class="p">)</span>
6062
</pre></div>
6163

6264
</div>

index.ipynb

+2
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@
4848
"metadata": {},
4949
"outputs": [],
5050
"source": [
51+
"from omeka_s_tools.api import OmekaAPIClient\n",
52+
"\n",
5153
"omeka = OmekaAPIClient('http://timsherratt.org/collections/api')"
5254
]
5355
},

omeka_s_tools/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "0.0.2"
1+
__version__ = "0.0.3"

settings.ini

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ author = Tim Sherratt
1313
author_email = [email protected]
1414
copyright = Tim Sherratt
1515
branch = master
16-
version = 0.0.2
16+
version = 0.0.3
1717
min_python = 3.6
1818
audience = Developers
1919
language = English

0 commit comments

Comments
 (0)