Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
易企天创
zendata
提交
efb1b021
Z
zendata
项目概览
易企天创
/
zendata
11 个月 前同步成功
通知
17
Star
2
Fork
1
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Z
zendata
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
efb1b021
编写于
3月 11, 2021
作者:
陈
陈琦
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update doc
上级
51164dce
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
24 addition
and
22 deletion
+24
-22
res/en/usage.txt
res/en/usage.txt
+5
-4
res/zh/usage.txt
res/zh/usage.txt
+5
-4
test/test.yaml
test/test.yaml
+14
-14
未找到文件。
res/en/usage.txt
浏览文件 @
efb1b021
...
...
@@ -28,9 +28,10 @@ Parameters:
Also you can output the readable format via -H.
-a --article Convert article to yaml config file in the dir provided by -o parameter.
-l --list List user's data.
-l List build-in data.
-v --view View the detailed definition of a data format.
-l --list List user's data in current dir.
-L List build-in data in ZenData install dir.
-v --view View detailed definition of a data format in current dir.
-V View detailed definition of a data format in ZenData install dir.
-h --help Print help.
-e --example Print the data format config file of the example.
...
...
@@ -63,6 +64,6 @@ $zd.exe -p 80 -R d:\zd\config # Listen port 80. Use d:\zd\config as th
Client Call:
$curl http:\\localhost:8848\?d=demo\default.yaml&c=demo\config.yaml&n=100
# Specify the server config file via GET.
$curl http:\\localhost:8848\?d=demo\default.yaml&c=demo\config.yaml&n=100
&T=true
# Specify the server config file via GET.
$curl http:\\localhost:8848\?default=demo\default.yaml&output=test.sql&table=user # Parameter names can be full.
$curl -i -X POST http:\\localhost:8848?lines=3 -F default=@demo\default.yaml # The config can be uploaded via POST.
res/zh/usage.txt
浏览文件 @
efb1b021
...
...
@@ -22,9 +22,10 @@ ZenData是一款通用的数据生成工具,您可以使用yaml文件来定义
-D --decode 根据指定的配置文件,将通过-i参数指定的数据文件解析成json格式。
-a --article 将指定的文件或目录下扩展名为.txt的文件,转换成文章yaml配置,输出到-o参数指定的目录下。
-l --list 列出用户数据。
-L 列出內置数据。
-v --view 查看某一个数据格式的详细定义。
-l --list 列出当前目录下所有的用户数据定义。
-L 列出ZenData安装目录下所有数据定义。
-v --view 查看当前目录下某个用户数据定义的详细信息。
-V 查看ZenData安装目录下某个数据定义的详细信息。
-h --help 打印帮助。
-e --example 打印示例的数据格式配置文件。
...
...
@@ -57,6 +58,6 @@ $zd.exe -p 80 -R d:\zd\config # 监听80
客户端调用:
$curl http://localhost:8848/?d=demo/default.yaml&c=demo/config.yaml&n=100
# 通过GET方式指定服务器端配置文件。
$curl http://localhost:8848/?d=demo/default.yaml&c=demo/config.yaml&n=100
&T=true
# 通过GET方式指定服务器端配置文件。
$curl http://localhost:8848/?default=demo/default.yaml&output=test.sql&table=user # 参数名可以用全拼。
$curl -i -X POST http://localhost:8848?lines=3 -F default=@demo/default.yaml # 可以通过POST方式上传配置文件。
test/test.yaml
浏览文件 @
efb1b021
...
...
@@ -2,21 +2,21 @@ title: test
desc
:
描述
version
:
1.0
fields
:
# - field: field
_text
#
range: res/num.txt, ../demo/user.txt:R
#
postfix: "\t"
-
field
:
refer
_text
range
:
res/num.txt, ../demo/user.txt:R
postfix
:
"
\t
"
# - field: firs
t
#
range: ../demo/15_from_range.yaml{3}, ../demo/16_from_instance.yaml{10}
#
prefix: ""
#
postfix: "\t"
-
field
:
refer_conten
t
range
:
../demo/15_from_range.yaml{3}, ../demo/16_from_instance.yaml{10}
prefix
:
"
"
postfix
:
"
\t
"
# - field: field_use_ranges_small
#
from: zentao.number.v1.yaml
#
use: small{3},netmask
#
postfix: "\t"
-
field
:
refer_ranges
from
:
zentao.number.v1.yaml
use
:
small{3},netmask
postfix
:
"
\t
"
-
field
:
field_use_instance
# 引用其他的定义文件,该文件定义了多个实例。
from
:
ip.v1.yaml
# yaml/ip/v1.yaml
use
:
privateA{3},privateB{5}
# 使用该文件中定义的privateC和privateB两个实例。
-
field
:
refer_instance
from
:
ip.v1.yaml
use
:
privateA{3},privateB{5}
postfix
:
"
\t
"
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录