-
Notifications
You must be signed in to change notification settings - Fork 15
/
.dkrc
39 lines (30 loc) · 1.34 KB
/
.dkrc
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
#!/usr/bin/env bash
# ---
# Add your own commands, functions, and variables here. Define defaults first,
# then `dk use:` the desired devkit modules, and then define any overrides to
# the devkit defaults.
# ---
# Available modules (uncomment to use):
dk use: cram # run tests using the "cram" functional test tool
dk use: modd-watch # watch files and re-run tests or other commands
dk use: shell-console # make the "console" command enter a subshell
dk use: bash32 # enable doing tests/console/etc. in bash3.2 w/docker
dk use: shellcheck # support running shellcheck (via docker if not installed)
# Define overrides, new commands, functions, etc. here:
# SC1090 = dynamic 'source' command
# SC2128 = array/string mixing
# SC2178 = array/string mixing
# SC2241 = exit messages
SHELLCHECK_OPTS='-e SC1090,SC2128,SC2178,SC2241'
compile-to() {
bin/mdsh --out "$1" --compile "$LOCO_ROOT/mdsh.md"
chmod +x "$1"
}
# Pre-build a copy of mdsh for tests
before test compile-to "$BASHER_INSTALL_BIN"/mdsh
# Don't run shellcheck on Travis: we need shellcheck PR #1302 for @funcs
[[ ${TRAVIS-} ]] || on test dk shellcheck "$BASHER_INSTALL_BIN"/mdsh
# Build the distribution version
before build dk test
on build compile-to bin/mdsh
watch+ "*.md" "specs/*" "!**/*.md.err" "!**/.~*.md" -- dk test