Source

tkf.bitbucket.org / neorg-doc / index.html

Full commit
  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>NEOrg Reference Guide &mdash; NEOrg v0.0.3.dev0 documentation</title>
    <link rel="stylesheet" href="_static/haiku.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    <link rel="stylesheet" href="_static/print.css" type="text/css" />
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '',
        VERSION:     '0.0.3.dev0',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/underscore.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>
    <script type="text/javascript" src="_static/theme_extras.js"></script>
    <link rel="top" title="NEOrg v0.0.3.dev0 documentation" href="#" />
    <link rel="next" title="Example usages of the special directives" href="examples.html" />
 
<script type="text/javascript">
  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-22829655-1']);
  _gaq.push(['_trackPageview']);
</script>

  </head>
  <body>
      <div class="header"><h1 class="heading"><a href="#">
          <span>NEOrg v0.0.3.dev0 documentation</span></a></h1>
        <h2 class="heading"><span>NEOrg Reference Guide</span></h2>
      </div>
      <div class="topnav">
      
        <p>
        <a class="uplink" href="#">Contents</a>
        &#160;&#160;::&#160;&#160;
        <a href="examples.html">Example usages of the special directives</a>&#160;&#160;»
        </p>

      </div>
      <div class="content">
        
        
  <div class="contents topic" id="contents">
<p class="topic-title first">Contents</p>
<ul class="simple">
<li><a class="reference internal" href="#neorg-reference-guide" id="id2">NEOrg Reference Guide</a><ul>
<li><a class="reference internal" href="#special-directives" id="id3">Special directives</a><ul>
<li><a class="reference internal" href="#show-data-in-a-table-table-data" id="id4">Show data in a table - <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a></a></li>
<li><a class="reference internal" href="#show-data-and-images-in-a-table-table-data-and-image" id="id5">Show data and images in a table - <a class="reference internal" href="#directive-table-data-and-image" title="table-data-and-image directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data-and-image</span></tt></a></a></li>
<li><a class="reference internal" href="#see-the-difference-of-data-dictdiff" id="id6">See the difference of data - <a class="reference internal" href="#directive-dictdiff" title="dictdiff directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">dictdiff</span></tt></a></a></li>
<li><a class="reference internal" href="#show-effects-of-the-parameter-change-grid-images" id="id7">Show effects of the parameter change - <a class="reference internal" href="#directive-grid-images" title="grid-images directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">grid-images</span></tt></a></a></li>
<li><a class="reference internal" href="#find-images-find-images" id="id8">Find images - <a class="reference internal" href="#directive-find-images" title="find-images directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">find-images</span></tt></a></a></li>
<li><a class="reference internal" href="#list-pages-list-pages" id="id9">List Pages - <a class="reference internal" href="#directive-list-pages" title="list-pages directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">list-pages</span></tt></a></a></li>
</ul>
</li>
<li><a class="reference internal" href="#template-page-temp" id="id10">Template page - <tt class="docutils literal"><span class="pre">_temp_</span></tt></a></li>
<li><a class="reference internal" href="#glossary" id="id11">Glossary</a></li>
<li><a class="reference internal" href="#configuration-variables" id="id12">Configuration variables</a></li>
<li><a class="reference internal" href="#faqs" id="id13">FAQs</a><ul>
<li><a class="reference internal" href="#how-do-i-make-a-new-page" id="id14">How do I make a new page?</a></li>
<li><a class="reference internal" href="#how-do-i-make-a-link-to-the-other-page" id="id15">How do I make a link to the other page?</a></li>
</ul>
</li>
<li><a class="reference internal" href="#docuitils-links" id="id16">Docuitils links</a></li>
<li><a class="reference internal" href="#other-contents" id="id17">Other contents</a></li>
</ul>
</li>
</ul>
</div>
<div class="section" id="neorg-reference-guide">
<h1><a class="toc-backref" href="#id2">NEOrg Reference Guide</a><a class="headerlink" href="#neorg-reference-guide" title="Permalink to this headline"></a></h1>
<div class="section" id="special-directives">
<span id="id1"></span><h2><a class="toc-backref" href="#id3">Special directives</a><a class="headerlink" href="#special-directives" title="Permalink to this headline"></a></h2>
<p>A <a class="reference internal" href="#term-directive"><em class="xref std std-term">directive</em></a> is a general <a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> block markup.
With the special directives defined by NEOrg, you can fetch data and
images, show them effectively, and organize your notes.</p>
<div class="section" id="show-data-in-a-table-table-data">
<h3><a class="toc-backref" href="#id4">Show data in a table - <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a></a><a class="headerlink" href="#show-data-in-a-table-table-data" title="Permalink to this headline"></a></h3>
<dl class="directive">
<dt id="directive-table-data">
<tt class="descname">.. table-data::</tt><tt class="descclassname"> path [path ...]</tt><a class="headerlink" href="#directive-table-data" title="Permalink to this definition"></a></dt>
<dd><p>Search data file under the given list of <cite>path</cite> and show matched
data.
You can use <a class="reference internal" href="#term-unix-shell-style-pattern-matching"><em class="xref std std-term">Unix shell-style pattern matching</em></a>.</p>
<dl class="docutils">
<dt>base <span class="classifier-delimiter">:</span> <span class="classifier">string (newlines removed)</span></dt>
<dd><p class="first">This is an optional parameter to specify the directory
where the data files are searched from.
The data files will be searched from <span class="target" id="index-0"></span><a class="reference internal" href="#envvar-DATADIRPATH"><tt class="xref std std-envvar docutils literal"><span class="pre">DATADIRPATH</span></tt></a> if
not specified.</p>
<p>For example,</p>
<div class="highlight-rst"><div class="highlight"><pre><span class="p">..</span> <span class="ow">table-data</span><span class="p">::</span> 2011-02-*/data.json
                2011-03-*/data.json
   <span class="nc">:base:</span> <span class="nf">my/experiment</span>
</pre></div>
</div>
<p class="last">will search the files matches to
<tt class="docutils literal"><span class="pre">my/experiment/2011-02-*/data.json</span></tt> and
<tt class="docutils literal"><span class="pre">my/experiment/2011-03-*/data.json</span></tt>.</p>
</dd>
<dt>data <span class="classifier-delimiter">:</span> <span class="classifier">text [, text, ...]</span></dt>
<dd>A comma- or space-separated list of the <a class="reference internal" href="#term-dictionary-path"><em class="xref std std-term">dictionary path</em></a>.
You can use <a class="reference internal" href="#term-unix-shell-style-pattern-matching"><em class="xref std std-term">Unix shell-style pattern matching</em></a>.</dd>
<dt>widths <span class="classifier-delimiter">:</span> <span class="classifier">integer [, integer...]</span></dt>
<dd>A comma- or space-separated list of relative column widths.</dd>
<dt>link <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd><p class="first">A comma- or space-separated list of path to the link(s).
Magic words <tt class="docutils literal"><span class="pre">%(path)s</span></tt> and <tt class="docutils literal"><span class="pre">%(relpath)s</span></tt> are available.</p>
<dl class="last docutils">
<dt><tt class="docutils literal"><span class="pre">%(path)s</span></tt></dt>
<dd>This represents full path to the parent directory of the
data file.</dd>
<dt><tt class="docutils literal"><span class="pre">%(relpath)s</span></tt></dt>
<dd>This is the relative path of the <tt class="docutils literal"><span class="pre">%(path)s</span></tt> from the
<a class="reference internal" href="#term-base"><em class="xref std std-term">base</em></a> directory.</dd>
</dl>
</dd>
<dt>path-order <span class="classifier-delimiter">:</span> <span class="classifier">{&#8216;sort&#8217;, &#8216;sort_r&#8217;}</span></dt>
<dd><p class="first">Sort the matched data paths.
<tt class="docutils literal"><span class="pre">sort</span></tt> will sort the paths in alphabetical order
and <tt class="docutils literal"><span class="pre">sort_r</span></tt> is the reversed version of <tt class="docutils literal"><span class="pre">sort</span></tt>.
The default is <tt class="docutils literal"><span class="pre">'sort'</span></tt>.
Note that</p>
<div class="highlight-rst"><div class="highlight"><pre><span class="p">..</span> <span class="ow">table-data</span><span class="p">::</span> 2011-02-*/data.json
                2011-03-*/data.json
   <span class="nc">:path-order:</span> <span class="nf">sort_r</span>
</pre></div>
</div>
<p>does not makes <tt class="docutils literal"><span class="pre">2011-03-01/data.json</span></tt> higher than
<tt class="docutils literal"><span class="pre">2011-02-01/data.json</span></tt>.  You will need to write</p>
<div class="last highlight-rst"><div class="highlight"><pre><span class="p">..</span> <span class="ow">table-data</span><span class="p">::</span> 2011-03-*/data.json
                2011-02-*/data.json
   <span class="nc">:path-order:</span> <span class="nf">sort_r</span>
</pre></div>
</div>
</dd>
<dt>trans <span class="classifier-delimiter">:</span> <span class="classifier">flag</span></dt>
<dd>Transpose the table.</dd>
</dl>
<div class="admonition-see-also admonition seealso">
<p class="first admonition-title">See also</p>
<p class="last"><a class="reference internal" href="examples.html#examples-table-data"><em>Example usages of table-data</em></a></p>
</div>
</dd></dl>

</div>
<div class="section" id="show-data-and-images-in-a-table-table-data-and-image">
<h3><a class="toc-backref" href="#id5">Show data and images in a table - <a class="reference internal" href="#directive-table-data-and-image" title="table-data-and-image directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data-and-image</span></tt></a></a><a class="headerlink" href="#show-data-and-images-in-a-table-table-data-and-image" title="Permalink to this headline"></a></h3>
<dl class="directive">
<dt id="directive-table-data-and-image">
<tt class="descname">.. table-data-and-image::</tt><tt class="descclassname"> path [path ...]</tt><a class="headerlink" href="#directive-table-data-and-image" title="Permalink to this definition"></a></dt>
<dd><p>Search data under the given list of <cite>path</cite> and show matched data and
corresponding image(s).
You can use <a class="reference internal" href="#term-unix-shell-style-pattern-matching"><em class="xref std std-term">Unix shell-style pattern matching</em></a>.</p>
<dl class="docutils">
<dt>base <span class="classifier-delimiter">:</span> <span class="classifier">string (newlines removed)</span></dt>
<dd>This is an optional parameter to specify the directory
where the data files are searched from.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>data <span class="classifier-delimiter">:</span> <span class="classifier">text [, text, ...]</span></dt>
<dd>A comma- or space-separated list of the <a class="reference internal" href="#term-dictionary-path"><em class="xref std std-term">dictionary path</em></a>.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>image <span class="classifier-delimiter">:</span> <span class="classifier">text [, text, ...]</span></dt>
<dd>A comma- or space-separated list of path to the images.
The path is the relative path from the parent directory of
the data file.</dd>
<dt>widths <span class="classifier-delimiter">:</span> <span class="classifier">integer [, integer...]</span></dt>
<dd>A comma- or space-separated list of relative column widths.
Note that the first column is data sub-table and the second and
the after are the images specified in <cite>:image:</cite>.</dd>
<dt>image-{OPTION} <span class="classifier-delimiter">:</span> <span class="classifier">integer:{VAL} [, integer:{VAL} ...]</span></dt>
<dd><cite>integer</cite> is the index of the image.
<cite>{VAL}</cite> specifies the value of the <cite>{OPTION}</cite> of the
<a class="reference external" href="http://docutils.sourceforge.net/docs/ref/rst/directives.html#image">image directive</a>.</dd>
<dt>link <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd>A comma- or space-separated list of path to the link(s).
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>path-order <span class="classifier-delimiter">:</span> <span class="classifier">{&#8216;sort&#8217;, &#8216;sort_r&#8217;}</span></dt>
<dd>Sort the matched data paths.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>sort <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd>A comma- or space-separated list of the <a class="reference internal" href="#term-dictionary-path"><em class="xref std std-term">dictionary path</em></a>.
The table will be sorted by values of the keys.</dd>
</dl>
<div class="admonition-see-also admonition seealso">
<p class="first admonition-title">See also</p>
<p class="last"><a class="reference internal" href="examples.html#examples-table-data-and-image"><em>Example usages of table-data-and-image</em></a></p>
</div>
</dd></dl>

</div>
<div class="section" id="see-the-difference-of-data-dictdiff">
<h3><a class="toc-backref" href="#id6">See the difference of data - <a class="reference internal" href="#directive-dictdiff" title="dictdiff directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">dictdiff</span></tt></a></a><a class="headerlink" href="#see-the-difference-of-data-dictdiff" title="Permalink to this headline"></a></h3>
<dl class="directive">
<dt id="directive-dictdiff">
<tt class="descname">.. dictdiff::</tt><tt class="descclassname"> path [path ...]</tt><a class="headerlink" href="#directive-dictdiff" title="Permalink to this definition"></a></dt>
<dd><p>Search data under the given list of <cite>path</cite> and show the difference
of the data.
You can use <a class="reference internal" href="#term-unix-shell-style-pattern-matching"><em class="xref std std-term">Unix shell-style pattern matching</em></a>.</p>
<dl class="docutils">
<dt>base <span class="classifier-delimiter">:</span> <span class="classifier">string (newlines removed)</span></dt>
<dd>This is an optional parameter to specify the directory
where the data files are searched from.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>link <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd>A comma- or space-separated list of path to the link(s).
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>include <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd>A comma- or space-separated list of <a class="reference internal" href="#term-regular-expression"><em class="xref std std-term">regular expression</em></a>
of the <a class="reference internal" href="#term-dictionary-path"><em class="xref std std-term">dictionary path</em></a> to include.</dd>
<dt>exclude <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd>A comma- or space-separated list of <a class="reference internal" href="#term-regular-expression"><em class="xref std std-term">regular expression</em></a>
of the <a class="reference internal" href="#term-dictionary-path"><em class="xref std std-term">dictionary path</em></a> to exclude.</dd>
<dt>path-order <span class="classifier-delimiter">:</span> <span class="classifier">{&#8216;sort&#8217;, &#8216;sort_r&#8217;}</span></dt>
<dd>Sort the matched data paths.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>trans <span class="classifier-delimiter">:</span> <span class="classifier">flag</span></dt>
<dd>Transpose the table.</dd>
</dl>
<div class="admonition-see-also admonition seealso">
<p class="first admonition-title">See also</p>
<p class="last"><a class="reference internal" href="examples.html#examples-dictdiff"><em>Example usages of dictdiff</em></a></p>
</div>
</dd></dl>

</div>
<div class="section" id="show-effects-of-the-parameter-change-grid-images">
<h3><a class="toc-backref" href="#id7">Show effects of the parameter change - <a class="reference internal" href="#directive-grid-images" title="grid-images directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">grid-images</span></tt></a></a><a class="headerlink" href="#show-effects-of-the-parameter-change-grid-images" title="Permalink to this headline"></a></h3>
<dl class="directive">
<dt id="directive-grid-images">
<tt class="descname">.. grid-images::</tt><tt class="descclassname"> path [path ...]</tt><a class="headerlink" href="#directive-grid-images" title="Permalink to this definition"></a></dt>
<dd><p>Search data and show the images related to the data on &#8220;<strong>grid</strong>&#8221;.
You can use <a class="reference internal" href="#term-unix-shell-style-pattern-matching"><em class="xref std std-term">Unix shell-style pattern matching</em></a>.</p>
<p>In experiments, you may change parameters systematically
to see what will happen.  For example, when you do experiments
varying two parameters <em>a=1, 2, 3</em> and <em>b=0.1, 0.2, 0.3</em>,
you will get 9 results.  Viewing the results in a linear list is
a bad idea: you should see it in a 3x3 matrix like this!:</p>
<table border="1" class="docutils">
<colgroup>
<col width="6%" />
<col width="31%" />
<col width="31%" />
<col width="31%" />
</colgroup>
<tbody valign="top">
<tr><td>&nbsp;</td>
<td><strong>b=0.1</strong></td>
<td><strong>b=0.2</strong></td>
<td><strong>b=0.3</strong></td>
</tr>
<tr><td><strong>a=1</strong></td>
<td>result with <em>a=1</em> and <em>b=0.1</em></td>
<td>result with <em>a=1</em> and <em>b=0.2</em></td>
<td>result with <em>a=1</em> and <em>b=0.3</em></td>
</tr>
<tr><td><strong>a=2</strong></td>
<td>result with <em>a=2</em> and <em>b=0.1</em></td>
<td>result with <em>a=2</em> and <em>b=0.2</em></td>
<td>result with <em>a=2</em> and <em>b=0.3</em></td>
</tr>
<tr><td><strong>a=3</strong></td>
<td>result with <em>a=3</em> and <em>b=0.1</em></td>
<td>result with <em>a=3</em> and <em>b=0.2</em></td>
<td>result with <em>a=3</em> and <em>b=0.3</em></td>
</tr>
</tbody>
</table>
<p>The grid is a N-dimensional version of this matrix.
To see it in 2D display (because we don&#8217;t have N-dim display),
NEOrg generates the nested table.</p>
<dl class="docutils">
<dt>base <span class="classifier-delimiter">:</span> <span class="classifier">string (newlines removed)</span></dt>
<dd>The base path for searching data. Real path to be used
This is an optional parameter to specify the directory
where the data files are searched from.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt>param <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd>A comma- or space-separated list of the <a class="reference internal" href="#term-dictionary-path"><em class="xref std std-term">dictionary path</em></a>
for the axes of the grid.</dd>
<dt>image <span class="classifier-delimiter">:</span> <span class="classifier">text [, text]</span></dt>
<dd>A comma- or space-separated list of path to the images.
The path is the relative path from the parent directory of
the data file.</dd>
</dl>
<div class="admonition-see-also admonition seealso">
<p class="first admonition-title">See also</p>
<p class="last"><a class="reference internal" href="examples.html#examples-grid-images"><em>Example usages of grid-images</em></a></p>
</div>
</dd></dl>

</div>
<div class="section" id="find-images-find-images">
<h3><a class="toc-backref" href="#id8">Find images - <a class="reference internal" href="#directive-find-images" title="find-images directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">find-images</span></tt></a></a><a class="headerlink" href="#find-images-find-images" title="Permalink to this headline"></a></h3>
<dl class="directive">
<dt id="directive-find-images">
<tt class="descname">.. find-images::</tt><tt class="descclassname"> path [path ...]</tt><a class="headerlink" href="#directive-find-images" title="Permalink to this definition"></a></dt>
<dd><p>Search images under the given list of <cite>path</cite> and show matched images.
You can use <a class="reference internal" href="#term-unix-shell-style-pattern-matching"><em class="xref std std-term">Unix shell-style pattern matching</em></a>.</p>
<dl class="docutils">
<dt>base <span class="classifier-delimiter">:</span> <span class="classifier">string (newlines removed)</span></dt>
<dd>This is an optional parameter to specify the directory
where the data files are searched from.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
</dl>
<div class="admonition-see-also admonition seealso">
<p class="first admonition-title">See also</p>
<p class="last"><a class="reference internal" href="examples.html#examples-find-images"><em>Example usage of find-images</em></a></p>
</div>
</dd></dl>

</div>
<div class="section" id="list-pages-list-pages">
<h3><a class="toc-backref" href="#id9">List Pages - <a class="reference internal" href="#directive-list-pages" title="list-pages directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">list-pages</span></tt></a></a><a class="headerlink" href="#list-pages-list-pages" title="Permalink to this headline"></a></h3>
<dl class="directive">
<dt id="directive-list-pages">
<tt class="descname">.. list-pages::</tt><tt class="descclassname"> </tt><a class="headerlink" href="#directive-list-pages" title="Permalink to this definition"></a></dt>
<dd><p>Insert list of sub-pages.</p>
</dd></dl>

</div>
</div>
<div class="section" id="template-page-temp">
<span id="template-page"></span><h2><a class="toc-backref" href="#id10">Template page - <tt class="docutils literal"><span class="pre">_temp_</span></tt></a><a class="headerlink" href="#template-page-temp" title="Permalink to this headline"></a></h2>
<p>When you do experiments repeatedly, you may want to see the results
in a fixed format.  The template page can be used for that purpose.</p>
<p>The page which has <tt class="docutils literal"><span class="pre">_temp_</span></tt> in its <a class="reference internal" href="#term-page-path"><em class="xref std std-term">page path</em></a> is a
<a class="reference internal" href="#term-template-page"><em class="xref std std-term">template page</em></a>.
The template page is used for generating page.
If the page path does not exist but the template page which matches to
the page path exists, generated page will be shown.</p>
<p>Examples of the template <a class="reference internal" href="#term-page-path"><em class="xref std std-term">page path</em></a>:</p>
<blockquote>
<div><ol class="loweralpha simple">
<li><tt class="docutils literal"><span class="pre">/my/page/_temp_/</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/my/page/_temp_/_temp_/</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/my/page/_temp_/images/</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/my/page/_temp_/subdata/_temp_/</span></tt></li>
<li><tt class="docutils literal"><span class="pre">/my/page/_temp_/_temp_/subdata</span></tt></li>
</ol>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">/my/page/2011-05-21/</span></tt> matches to (a)</li>
<li><tt class="docutils literal"><span class="pre">/my/page/2011-05-21/some-data/</span></tt> matches to (b)</li>
<li><tt class="docutils literal"><span class="pre">/my/page/2011-05-21/images/</span></tt> matches to (c)</li>
<li><tt class="docutils literal"><span class="pre">/my/page/2011-05-21/subdata/000/</span></tt> matches to (d)</li>
<li><tt class="docutils literal"><span class="pre">/my/page/2011-05-21/000/subdata/</span></tt> matches to (e)</li>
<li><tt class="docutils literal"><span class="pre">/my/page/2011-05-21/subdata/subdata/</span></tt> matches to (e)</li>
</ul>
</div></blockquote>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">{{</span> <span class="pre">args[N]</span> <span class="pre">}}</span></tt> (where <tt class="docutils literal"><span class="pre">N</span></tt> is an integer)</dt>
<dd>N-th replacement of the <tt class="docutils literal"><span class="pre">_temp_</span></tt> in the URL.
For example, at the page <tt class="docutils literal"><span class="pre">/my/page/2011-05-21/subdata/000/</span></tt>
in the above example, <tt class="docutils literal"><span class="pre">{{</span> <span class="pre">args[0]</span> <span class="pre">}}</span></tt> and <tt class="docutils literal"><span class="pre">{{</span> <span class="pre">args[1]</span> <span class="pre">}}</span></tt>
will be replaced by <tt class="docutils literal"><span class="pre">2011-05-21</span></tt> and <tt class="docutils literal"><span class="pre">000</span></tt>.</dd>
<dt><tt class="docutils literal"><span class="pre">{{</span> <span class="pre">path</span> <span class="pre">}}</span></tt></dt>
<dd>This will be replaced by the full path to this directory.</dd>
<dt><tt class="docutils literal"><span class="pre">{{</span> <span class="pre">relpath</span> <span class="pre">}}</span></tt></dt>
<dd>This will be replaced by the relative path from the parent page of
the leftmost <tt class="docutils literal"><span class="pre">_temp_</span></tt> page.</dd>
</dl>
<div class="admonition-see-also admonition seealso">
<p class="first admonition-title">See also</p>
<p class="last"><a class="reference internal" href="examples.html#examples-template-page"><em>Example usages of the template page</em></a></p>
</div>
</div>
<div class="section" id="glossary">
<h2><a class="toc-backref" href="#id11">Glossary</a><a class="headerlink" href="#glossary" title="Permalink to this headline"></a></h2>
<dl class="glossary docutils">
<dt id="term-directive">directive</dt>
<dd><p class="first">A directive is one of the <a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> block markup in
the following shape:</p>
<div class="highlight-rst"><div class="highlight"><pre><span class="p">..</span> <span class="ow">directive-name</span><span class="p">::</span> argument(s)
   <span class="nc">:option:</span> <span class="nf">parameter</span>
   <span class="nc">:another_option:</span> <span class="nf">another_parameter</span>

   some contents
</pre></div>
</div>
<p>See <a class="reference external" href="http://docutils.sourceforge.net/docs/ref/rst/directives.html">reStructuredText Directives</a> for more information and
the basic directives defined by docutils.</p>
<p class="last">NEOrg defines varikous special for displaying and organizing
data effectively (see <a class="reference internal" href="#special-directives"><em>Special directives</em></a>).</p>
</dd>
<dt id="term-page-path">page path</dt>
<dd>The page path is the URL to the page.</dd>
<dt id="term-unix-shell-style-pattern-matching">unix shell-style pattern matching</dt>
<dd><p class="first">Unix shell-style pattern matching supports the following
wild-cards.</p>
<table border="1" class="last docutils">
<colgroup>
<col width="25%" />
<col width="75%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">Pattern</th>
<th class="head">Meaning</th>
</tr>
</thead>
<tbody valign="top">
<tr><td><tt class="docutils literal"><span class="pre">*</span></tt></td>
<td>matches everything</td>
</tr>
<tr><td><tt class="docutils literal"><span class="pre">?</span></tt></td>
<td>matches any single character</td>
</tr>
<tr><td><tt class="docutils literal"><span class="pre">[seq]</span></tt></td>
<td>matches any character in <em>seq</em></td>
</tr>
<tr><td><tt class="docutils literal"><span class="pre">[!seq]</span></tt></td>
<td>matches any character not in <em>seq</em></td>
</tr>
</tbody>
</table>
</dd>
<dt id="term-base"><tt class="docutils literal"><span class="pre">base</span></tt></dt>
<dd>This is the optional parameter for the directives which searches
the data files.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt id="term-link"><tt class="docutils literal"><span class="pre">link</span></tt></dt>
<dd>This is the optional parameter for the directives which generates
the links to the other pages.
See <a class="reference internal" href="#directive-table-data" title="table-data directive"><tt class="xref rst rst-dir docutils literal"><span class="pre">table-data</span></tt></a> for the details.</dd>
<dt id="term-magic-words">magic words</dt>
<dd><p class="first">Magic words are the special words which are replaced by NEOrg.</p>
<p>Magic words <tt class="docutils literal"><span class="pre">%(path)s</span></tt> and <tt class="docutils literal"><span class="pre">%(relpath)s</span></tt> are available
in the <a class="reference internal" href="#term-link"><em class="xref std std-term">link</em></a> parameter.</p>
<p class="last">Magic words <tt class="docutils literal"><span class="pre">%(root)s</span></tt> and <tt class="docutils literal"><span class="pre">%(neorg)s</span></tt> are available in the
configuration file for the variables <span class="target" id="index-1"></span><a class="reference internal" href="#envvar-DATADIRPATH"><tt class="xref std std-envvar docutils literal"><span class="pre">DATADIRPATH</span></tt></a> and
<span class="target" id="index-2"></span><a class="reference internal" href="#envvar-DATABASE"><tt class="xref std std-envvar docutils literal"><span class="pre">DATABASE</span></tt></a>.</p>
</dd>
<dt id="term-dictionary-path">dictionary path</dt>
<dd><p class="first">To specify the value in the nested dictionary, NEOrg uses
period-separated keys.  For example, the values in the
following nested dictionary can be accessed by the
&#8220;dictionary path&#8221; such as <tt class="docutils literal"><span class="pre">'key1.nestedkey1'</span></tt>.</p>
<div class="last highlight-js"><div class="highlight"><pre><span class="p">{</span><span class="s1">&#39;key1&#39;</span><span class="o">:</span> <span class="p">{</span>
     <span class="s1">&#39;nestedkey1&#39;</span><span class="o">:</span> <span class="mi">1</span><span class="p">,</span>
     <span class="s1">&#39;nestedkey2&#39;</span><span class="o">:</span> <span class="mi">2</span>
 <span class="p">}</span>
 <span class="s1">&#39;key2&#39;</span><span class="o">:</span> <span class="mi">2</span>
<span class="p">}</span>
</pre></div>
</div>
</dd>
<dt id="term-regular-expression">regular expression</dt>
<dd><p class="first">NEOrg uses python regular expression to filtering out/in
<a class="reference internal" href="#term-dictionary-path"><em class="xref std std-term">dictionary path</em></a>.</p>
<p class="last">See <a class="reference external" href="http://docs.python.org/library/re.html#re-syntax">Regular Expression Syntax &#8212; Python documentation</a> for
more information about the regular expression syntax.</p>
</dd>
<dt id="term-template-page">template page</dt>
<dd>A template page is the page which has at least one <tt class="docutils literal"><span class="pre">_temp_</span></tt>
in its <a class="reference internal" href="#term-page-path"><em class="xref std std-term">page path</em></a>.
See also <a class="reference internal" href="#template-page"><em>Template page - _temp_</em></a>.</dd>
<dt id="term-debug-mode">debug mode</dt>
<dd><p class="first">In debug mode, python interactive shell will be invoked in your
browser when NEOrg clashes.
See <a class="reference external" href="http://werkzeug.pocoo.org/docs/debug/">Debugging Applications &#8211; Werkzeug documentation</a> and
<a class="reference external" href="http://flask.pocoo.org/docs/quickstart/#debug-mode">Debug Mode &#8212; Flask documentation</a>  for more information.</p>
<div class="last admonition warning">
<p class="first admonition-title">Warning</p>
<p class="last">If someone can access to the
NEOrg running in debug mode, he can do anything your python
can do, such as deleting files.  Thus, <strong>debug mode should
not be used on an untrusted network.</strong></p>
</div>
</dd>
</dl>
</div>
<div class="section" id="configuration-variables">
<h2><a class="toc-backref" href="#id12">Configuration variables</a><a class="headerlink" href="#configuration-variables" title="Permalink to this headline"></a></h2>
<dl class="envvar">
<dt id="envvar-DATADIRPATH">
<tt class="descname">DATADIRPATH</tt><a class="headerlink" href="#envvar-DATADIRPATH" title="Permalink to this definition"></a></dt>
<dd><p>Path to your data directory.
<a class="reference internal" href="#term-magic-words"><em class="xref std std-term">Magic words</em></a> <tt class="docutils literal"><span class="pre">%(root)s</span></tt> and <tt class="docutils literal"><span class="pre">%(neorg)s</span></tt> are available.
The string <tt class="docutils literal"><span class="pre">~</span></tt> will be replaced by the user&#8217;s home directory.
Also, the environment variables are available.  For example, you
can also use <tt class="docutils literal"><span class="pre">$HOME</span></tt> or <tt class="docutils literal"><span class="pre">${HOME}</span></tt> to specify your home directory.
The default is <tt class="docutils literal"><span class="pre">%(root)s</span></tt>.</p>
<dl class="docutils">
<dt><tt class="docutils literal"><span class="pre">%(root)s</span></tt></dt>
<dd>The directory you specified by <tt class="docutils literal"><span class="pre">neorg</span> <span class="pre">init</span></tt> command.
If you did not specify, this is the directory where you ran
<tt class="docutils literal"><span class="pre">neorg</span> <span class="pre">init</span></tt> command.</dd>
<dt><tt class="docutils literal"><span class="pre">%(neorg)s</span></tt></dt>
<dd>This is equivalent to <tt class="docutils literal"><span class="pre">%(root)s/.neorg/</span></tt>.</dd>
</dl>
</dd></dl>

<dl class="envvar">
<dt id="envvar-DATABASE">
<tt class="descname">DATABASE</tt><a class="headerlink" href="#envvar-DATABASE" title="Permalink to this definition"></a></dt>
<dd><p>The path to the sqlite data base file.
<a class="reference internal" href="#term-magic-words"><em class="xref std std-term">Magic words</em></a> <tt class="docutils literal"><span class="pre">%(root)s</span></tt> and <tt class="docutils literal"><span class="pre">%(neorg)s</span></tt>,
special character <tt class="docutils literal"><span class="pre">~</span></tt>, and the environment variables are available.
The default is <tt class="docutils literal"><span class="pre">'%(neorg)s/neorg.db'</span></tt>.</p>
</dd></dl>

<dl class="envvar">
<dt id="envvar-DEBUG">
<tt class="descname">DEBUG</tt><a class="headerlink" href="#envvar-DEBUG" title="Permalink to this definition"></a></dt>
<dd><p>If it is set to <tt class="xref docutils literal"><span class="pre">True</span></tt>, <tt class="docutils literal"><span class="pre">neorg</span> <span class="pre">serve</span></tt> runs in <a class="reference internal" href="#term-debug-mode"><em class="xref std std-term">debug mode</em></a>
always.</p>
</dd></dl>

</div>
<div class="section" id="faqs">
<h2><a class="toc-backref" href="#id13">FAQs</a><a class="headerlink" href="#faqs" title="Permalink to this headline"></a></h2>
<div class="section" id="how-do-i-make-a-new-page">
<h3><a class="toc-backref" href="#id14">How do I make a new page?</a><a class="headerlink" href="#how-do-i-make-a-new-page" title="Permalink to this headline"></a></h3>
<p>Just type a page path to the browser&#8217;s address bar, e.g.:</p>
<div class="highlight-python"><pre>http://localhost:8000/my/new/page/</pre>
</div>
<p>and then you will see the edit form, if the page does not exist.</p>
</div>
<div class="section" id="how-do-i-make-a-link-to-the-other-page">
<h3><a class="toc-backref" href="#id15">How do I make a link to the other page?</a><a class="headerlink" href="#how-do-i-make-a-link-to-the-other-page" title="Permalink to this headline"></a></h3>
<p>If a string starts with <tt class="docutils literal"><span class="pre">/</span></tt>, <tt class="docutils literal"><span class="pre">./</span></tt> or <tt class="docutils literal"><span class="pre">../</span></tt>, ends with <tt class="docutils literal"><span class="pre">/</span></tt>
and contains only alphabets, numbers and <tt class="docutils literal"><span class="pre">_.+-`</span></tt> then it will
be regarded as a link.  For example:</p>
<div class="highlight-python"><pre>/full/path/link/
./link/to/a/sub/page/
../link/to/a/sibling/page/</pre>
</div>
<p>Note that this markup is weaker than any other <a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a>
markups.  For example, the following is not regraded as a link:</p>
<div class="highlight-python"><pre>/texsts_with_a_-hyphen-after-the-under_score/</pre>
</div>
<p>This is because <tt class="docutils literal"><span class="pre">texsts_with_a_</span></tt> is regraded as a hyper linke
target (and you will get a &#8220;Docutils Sysmtem Message&#8221; unexpectedly!).
You should escape the &#8220;tailing&#8221; underscore <tt class="docutils literal"><span class="pre">_</span></tt> with a slash <tt class="docutils literal"><span class="pre">\</span></tt>
like this:</p>
<div class="highlight-python"><pre>/texsts_with_a\_-hyphen-after-the-under_score/</pre>
</div>
</div>
</div>
<div class="section" id="docuitils-links">
<h2><a class="toc-backref" href="#id16">Docuitils links</a><a class="headerlink" href="#docuitils-links" title="Permalink to this headline"></a></h2>
<ul class="simple">
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/">Docutils Project Documentation Overview</a><ul>
<li><a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a><ul>
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/user/rst/quickstart.html">A ReStructuredText Primer</a></li>
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/user/rst/quickref.html">Quick reStructuredText</a></li>
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/user/rst/cheatsheet.txt">reStructuredText Cheat Sheet (text only)</a></li>
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/user/rst/demo.html">reStructuredText Demonstration</a></li>
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html">reStructuredText Markup Specification</a></li>
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/ref/rst/directives.html">reStructuredText Directives</a></li>
<li><a class="reference external" href="http://docutils.sourceforge.net/docs/ref/rst/roles.html">reStructuredText Interpreted Text Roles</a></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="section" id="other-contents">
<h2><a class="toc-backref" href="#id17">Other contents</a><a class="headerlink" href="#other-contents" title="Permalink to this headline"></a></h2>
<div class="toctree-wrapper compound">
<ul>
<li class="toctree-l1"><a class="reference internal" href="examples.html">Example usages of the special directives</a></li>
<li class="toctree-l1"><a class="reference internal" href="examples.html#example-usages-of-the-template-page">Example usages of the template page</a></li>
<li class="toctree-l1"><a class="reference internal" href="commands.html">NEOrg commands</a></li>
<li class="toctree-l1"><a class="reference internal" href="changelog.html">ChangeLog</a></li>
</ul>
</div>
</div>
</div>


      </div>
      <div class="bottomnav">
      
        <p>
        <a class="uplink" href="#">Contents</a>
        &#160;&#160;::&#160;&#160;
        <a href="examples.html">Example usages of the special directives</a>&#160;&#160;»
        </p>

      </div>


    <div class="footer">
        &copy; Copyright 2011, Takafumi Arakaki.
      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.0.7.
    </div>
<div class="footer">This page uses <a href="http://analytics.google.com/">
Google Analytics</a> to collect statistics. You can disable it by blocking
the JavaScript coming from www.google-analytics.com.
<script type="text/javascript">
  (function() {
    var ga = document.createElement('script');
    ga.src = ('https:' == document.location.protocol ?
              'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    ga.setAttribute('async', 'true');
    document.documentElement.firstChild.appendChild(ga);
  })();
</script>
</div>

  </body>
</html>