2015-12-28 22:03:16 +01:00
|
|
|
task build, "Compile the YAML module into a library":
|
2016-04-02 17:48:22 +02:00
|
|
|
--app:lib
|
|
|
|
--d:release
|
|
|
|
setCommand "c", "yaml"
|
2015-12-28 22:03:16 +01:00
|
|
|
|
|
|
|
task tests, "Run all tests":
|
2016-04-02 17:48:22 +02:00
|
|
|
--r
|
|
|
|
--verbosity:0
|
|
|
|
setCommand "c", "test/tests"
|
2015-12-28 22:03:16 +01:00
|
|
|
|
2016-10-09 15:05:18 +02:00
|
|
|
task lexerTests, "Run lexer tests":
|
2016-04-02 17:48:22 +02:00
|
|
|
--r
|
|
|
|
--verbosity:0
|
2016-10-09 15:05:18 +02:00
|
|
|
setCommand "c", "test/tlex"
|
|
|
|
|
|
|
|
task parserTests, "Run parser tests":
|
|
|
|
--r
|
|
|
|
--verbosity:0
|
|
|
|
setCommand "c", "test/tparser"
|
2016-03-04 19:10:48 +01:00
|
|
|
|
2016-10-09 16:10:11 +02:00
|
|
|
task jsonTests, "Run JSON tests":
|
|
|
|
--r
|
|
|
|
--verbosity:0
|
|
|
|
setCommand "c", "test/tjson"
|
|
|
|
|
|
|
|
task domTests, "Run DOM tests":
|
|
|
|
--r
|
|
|
|
--verbosity:0
|
|
|
|
setCommand "c", "test/tdom"
|
|
|
|
|
2015-12-29 15:09:37 +01:00
|
|
|
task serializationTests, "Run serialization tests":
|
2016-04-02 17:48:22 +02:00
|
|
|
--r
|
|
|
|
--verbosity:0
|
2016-10-09 15:05:18 +02:00
|
|
|
setCommand "c", "test/tserialization"
|
|
|
|
|
|
|
|
task quickstartTests, "Run quickstart tests":
|
|
|
|
--r
|
|
|
|
--verbosity:0
|
|
|
|
setCommand "c", "test/tquickstart"
|
2015-12-29 15:09:37 +01:00
|
|
|
|
2016-01-13 22:43:12 +01:00
|
|
|
task documentation, "Generate documentation":
|
2016-04-02 17:48:22 +02:00
|
|
|
exec "mkdir -p docout"
|
2016-10-08 18:38:27 +02:00
|
|
|
withDir "doc":
|
|
|
|
exec r"nim c rstPreproc"
|
|
|
|
exec r"./rstPreproc -o:tmp.rst index.txt"
|
|
|
|
exec r"nim rst2html -o:../docout/index.html tmp.rst"
|
|
|
|
exec r"./rstPreproc -o:tmp.rst api.txt"
|
|
|
|
exec r"nim rst2html -o:../docout/api.html tmp.rst"
|
|
|
|
exec r"./rstPreproc -o:tmp.rst serialization.txt"
|
|
|
|
exec r"nim rst2html -o:../docout/serialization.html tmp.rst"
|
2016-11-01 12:40:53 +01:00
|
|
|
exec r"nim rst2html -o:../docout/testing.html testing.rst"
|
|
|
|
exec r"nim rst2html -o:../docout/schema.html schema.rst"
|
2016-10-27 18:57:32 +02:00
|
|
|
exec "cp docutils.css style.css processing.svg ../docout"
|
2016-04-02 17:48:22 +02:00
|
|
|
exec r"nim doc2 -o:docout/yaml.html --docSeeSrcUrl:https://github.com/flyx/NimYAML/blob/`git log -n 1 --format=%H` yaml"
|
2016-09-22 14:06:54 +02:00
|
|
|
for file in listFiles("yaml"):
|
|
|
|
let packageName = file[5..^5]
|
|
|
|
exec r"nim doc2 -o:docout/yaml." & packageName &
|
|
|
|
".html --docSeeSrcUrl:https://github.com/flyx/NimYAML/blob/yaml/`git log -n 1 --format=%H` " &
|
|
|
|
file
|
2016-04-02 17:48:22 +02:00
|
|
|
setCommand "nop"
|
2015-12-28 22:13:14 +01:00
|
|
|
|
2015-12-29 00:14:47 +01:00
|
|
|
task bench, "Benchmarking":
|
2016-04-02 17:48:22 +02:00
|
|
|
--r
|
|
|
|
--w:off
|
|
|
|
--hints:off
|
2016-09-14 14:44:09 +02:00
|
|
|
--d:release
|
2016-04-02 17:48:22 +02:00
|
|
|
setCommand "c", "bench/bench"
|
2015-12-29 00:14:47 +01:00
|
|
|
|
2015-12-28 22:13:14 +01:00
|
|
|
task clean, "Remove all generated files":
|
2016-04-02 17:48:22 +02:00
|
|
|
exec "rm -rf libyaml.* test/tests test/parsing test/lexing bench/json docout"
|
|
|
|
setCommand "nop"
|
2016-01-05 21:34:07 +01:00
|
|
|
|
|
|
|
task server, "Compile server daemon":
|
2016-04-02 17:48:22 +02:00
|
|
|
--d:release
|
2017-02-14 19:06:41 +01:00
|
|
|
--d:yamlScalarRepInd
|
2016-04-02 17:48:22 +02:00
|
|
|
setCommand "c", "server/server"
|
2017-01-09 19:09:07 +01:00
|
|
|
|
|
|
|
task testSuiteEvents, "Compile the testSuiteEvents tool":
|
|
|
|
--d:release
|
|
|
|
setCommand "c", "tools/testSuiteEvents"
|