-
Notifications
You must be signed in to change notification settings - Fork 5
/
glob.nimble
30 lines (26 loc) · 1.07 KB
/
glob.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
version = "0.11.3"
author = "Bo Lingen"
description = "Pure library for matching file paths against Unix style glob patterns."
license = "MIT"
srcDir = "src"
skipDirs = @["docsrc"]
skipFiles = @["tests.nim"]
requires "nim >= 1.0.0"
requires "regex >= 0.20.0"
task test, "Run the test suite":
exec "nimble c -y --hints:off --verbosity:0 -r tests.nim"
task docs, "Generate the documentation":
rmDir("docs")
exec "nim doc --project -o:docs src/glob.nim"
cpFile("docsrc/redirect.html", "docs/index.html")
task prep_release, "Prepare for release":
if "fugitive".findExe == "":
echo "Could not locate `fugitive` for updating the changelog."
echo "Please run `nimble install fugitive` or ensure it is in your PATH."
elif "git".findExe == "":
echo "Could not locate `git`. Please install it or ensure it is in your PATH."
else:
exec "fugitive changelog changelog.md -t:v" & version
exec "git add changelog.md glob.nimble"
exec "git commit -m 'release: " & version & "'"
exec "git tag -a v" & version & " -m v" & version