-
Notifications
You must be signed in to change notification settings - Fork 10
/
noise.nimble
38 lines (32 loc) · 1.33 KB
/
noise.nimble
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
# packageName = "noise"
version = "0.1.10"
author = "Andri Lim"
description = "noise is a Nim implementation of linenoise"
license = "MIT"
skipDirs = @["examples"]
requires: "nim >= 0.18.1"
### Helper functions
proc test(env, path: string) =
# Compilation language is controlled by TEST_LANG
var lang = "c"
if existsEnv"TEST_LANG":
lang = getEnv"TEST_LANG"
if not dirExists "build":
mkDir "build"
exec "nim " & lang & " " & env &
" --hints:off --warnings:off " & path
task test, "Run all tests":
test "-d:prompt_no_history", "examples/test"
test "-d:prompt_no_kill", "examples/test"
test "-d:prompt_no_completion", "examples/test"
test "-d:prompt_no_word_editing", "examples/test"
test "-d:prompt_no_preload_buffer", "examples/test"
test "-d:prompt_no_incremental_history_search", "examples/test"
test "-d:release -d:prompt_no_history", "examples/test"
test "-d:release -d:prompt_no_kill", "examples/test"
test "-d:release -d:prompt_no_completion", "examples/test"
test "-d:release -d:prompt_no_word_editing", "examples/test"
test "-d:release -d:prompt_no_preload_buffer", "examples/test"
test "-d:release -d:prompt_no_incremental_history_search", "examples/test"
test "-d:release -d:prompt_no_basic", "examples/primitives"
test "-d:prompt_no_basic", "examples/primitives"