-
Notifications
You must be signed in to change notification settings - Fork 2
/
index.html
317 lines (315 loc) · 7.06 KB
/
index.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="Content-Type" name="viewport" content="width=device-width, initial-scale=1"/>
<title>zfinder</title>
<link rel="stylesheet" href="https://leungwensen.github.io/zfinder/dist/lib/normalize-4.2.0.min.css">
<link rel="stylesheet" href="https://leungwensen.github.io/zfinder/dist/lib/github-markdown-2.3.0.min.css">
<link rel="stylesheet" href="https://leungwensen.github.io/zfinder/dist/zfinder/markdown-previewer.css">
</head>
<body>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1"
style="width:0;height:0;position:absolute;overflow:hidden;">
<defs>
<symbol id="si-zfinder-collapse-left" viewBox="0 0 38 38">
<path d="M38 0H0v38h38V0zM3 35V3h32v32H3zM5 5v28h17V21h-9.667L16 26h-4l-5-7 5-7h4l-3.667 5H22V5H5z"/>
</symbol>
<symbol id="si-zfinder-expand-right" viewBox="0 0 38 38">
<path d="M0 0h38v38H0V0zm35 35V3H3v32h32zM22 5v28H5V21h9.667L11 26h4l5-7-5-7h-4l3.667 5H5V5h17z"/>
</symbol>
<symbol id="si-zfinder-fullscreen" viewBox="0 0 28 28">
<path d="M4 18H0v10h10v-4H4v-6zm-4-8h4V4h6V0H0v10zm24 14h-6v4h10V18h-4v6zM18 0v4h6v6h4V0H18z"/>
</symbol>
<symbol id="si-zfinder-fullscreen-exit" viewBox="0 0 28 28">
<path d="M0 22h6v6h4V18H0v4zM6 6H0v4h10V0H6v6zm12 22h4v-6h6v-4H18v10zm4-22V0h-4v10h10V6h-6z"/>
</symbol>
</defs>
</svg>
<nav id="toc">
<div id="toc-body" class="toc-body"></div>
</nav>
<article id="markdown">
<nav id="markdown-header" class="markdown-header">
<svg class="si" id="toggle-toc" width="24" height="24">
<use xlink:href="#si-zfinder-collapse-left"></use>
</svg>
<svg class="si float-right" id="toggle-fullscreen-article" width="24" height="24">
<use xlink:href="#si-zfinder-fullscreen"></use>
</svg>
</nav>
<div id="markdown-body" class="markdown-body"><h1>zfinder</h1>
<p>zfinder is a simple, powerful, flexible <strong>static server</strong> (B/S structure).</p>
<p>you can setup a static server with markdown support and lots of other features using one command: <code>$ zfinder serve</code></p>
<h2>installation</h2>
<pre><code class="language-shell">$ npm install zfinder -g
</code></pre>
<h2>usage</h2>
<h3>starting a zfinder server</h3>
<pre><code class="language-shell">$ zfinder serve
</code></pre>
<h3>building files</h3>
<p>building is to convert source files of specified formats(Markdown, etc.) into target formats.</p>
<figure><img src="./doc/dot/building-map.png" alt="building-map"></figure>
<p>build all files in a directory</p>
<pre><code class="language-shell">$ zfinder build $directory
</code></pre>
<p>build one file</p>
<pre><code class="language-shell">$ zfinder build $file
</code></pre>
<h3>kill all existing zfinder processes</h3>
<pre><code class="language-shell">$ zfinder kill
</code></pre>
<h2>handlers</h2>
<p>handlers are designed to deal with specific urls, or serve as an web API.</p>
<h3>authorization</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>basic-auth</td>
<td>adding basic authorization for urls</td>
<td>yes</td>
</tr>
</tbody>
</table>
<h3>file system</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>explorer</td>
<td>explores directories like finder.app or explorer.exe</td>
<td>partly</td>
</tr>
<tr>
<td>make-dir</td>
<td>creating a directory</td>
<td>yes</td>
</tr>
<tr>
<td>read-dir</td>
<td>returning stats of paths in a directory</td>
<td>yes</td>
</tr>
<tr>
<td>read-file</td>
<td>returning stats and file content</td>
<td>yes</td>
</tr>
<tr>
<td>remove-path</td>
<td>removing a path(file or directory)</td>
<td>yes</td>
</tr>
<tr>
<td>rename-path</td>
<td>renaming a path(file or directory)</td>
<td>yes</td>
</tr>
<tr>
<td>write-file</td>
<td>creating or updating a file</td>
<td>yes</td>
</tr>
</tbody>
</table>
<h3>searching</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>content-search</td>
<td>searching keyword in content of files</td>
<td>yes</td>
</tr>
<tr>
<td>glob-search</td>
<td>searching with glob expression for path names</td>
<td>yes</td>
</tr>
<tr>
<td>indexed-pathname-search</td>
<td>searching for path names with indexes</td>
<td>no</td>
</tr>
<tr>
<td>indexed-content-search</td>
<td>searching keyword in content of files with indexes</td>
<td>no</td>
</tr>
</tbody>
</table>
<h3><a href="http://www.graphviz.org/">graphviz</a> (supporting the DOT language via <a href="https://github.com/mdaines/viz.js/">viz.js</a>)</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>dot-editor</td>
<td>editing DOT file</td>
<td>no</td>
</tr>
<tr>
<td>dot-previewer</td>
<td>previewing DOT file</td>
<td>yes</td>
</tr>
<tr>
<td>dot-renderer</td>
<td>rendering DOT code</td>
<td>yes</td>
</tr>
</tbody>
</table>
<h3><a href="http://plantuml.com">plantUML</a> (TODO: converting plantUML into DOT using pure javascript version)</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>plantuml-editor</td>
<td>editing plantuml file</td>
<td>no</td>
</tr>
<tr>
<td>plantuml-previewer</td>
<td>previewing plantuml file</td>
<td>yes</td>
</tr>
<tr>
<td>plantuml-renderer</td>
<td>rendering plantuml code</td>
<td>yes</td>
</tr>
</tbody>
</table>
<h3>markdown</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>markdown-editor</td>
<td>editing markdown file</td>
<td>no</td>
</tr>
<tr>
<td>markdown-previewer</td>
<td>previewing markdown file</td>
<td>yes</td>
</tr>
<tr>
<td>markdown-renderer</td>
<td>rendering markdown file</td>
<td>yes</td>
</tr>
</tbody>
</table>
<h3>xmind</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>xmind-editor</td>
<td>editing xmind file</td>
<td>no</td>
</tr>
<tr>
<td>xmind-previewer</td>
<td>previewing xmind file</td>
<td>no</td>
</tr>
</tbody>
</table>
<h3>text</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>text-editor</td>
<td>editing text file</td>
<td>partly</td>
</tr>
</tbody>
</table>
<h3>fallback</h3>
<table>
<thead>
<tr>
<th>name</th>
<th>description</th>
<th>supported</th>
</tr>
</thead>
<tbody>
<tr>
<td>serve-index</td>
<td>automatically add a suffix to current url if that matches a file</td>
<td>yes</td>
</tr>
<tr>
<td>serve-static</td>
<td>urls that are not processed by other handlers will be pass to <code>node-static</code></td>
<td>yes</td>
</tr>
</tbody>
</table>
</div>
</article>
<div id="loading">
<div class="sk-double-bounce">
<div class="sk-child sk-double-bounce1"></div>
<div class="sk-child sk-double-bounce2"></div>
</div>
</div>
<script src="https://leungwensen.github.io/zfinder/dist/lib/jquery-3.1.0.min.js"></script>
<script src="https://leungwensen.github.io/zfinder/dist/lib/screenfull-3.0.0.min.js"></script>
<script src="https://leungwensen.github.io/zfinder/dist/zfinder/markdown-previewer.js"></script>
</body>
</html>