Skip to content

Commit 7ffbc70

Browse files
authored
Merge pull request #40 from nodenv/lint
linting
2 parents 5ea6e5e + 8415004 commit 7ffbc70

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

.travis.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
11
language: node_js
22
node_js: node
3-
# Lint and test in parallel
4-
script:
5-
- npm run lint
6-
- npm test
3+
cache: npm

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,10 @@
2222
"test": "test"
2323
},
2424
"scripts": {
25-
"lint": "git ls-files bin etc libexec | xargs shellcheck",
25+
"lint": "git ls-files bin etc libexec test/*.bash | xargs shellcheck",
2626
"pretest": "[ -d $npm_package_directories_testnodenv ] || git clone --quiet --depth 1 https://github.com/nodenv/nodenv $npm_package_directories_testnodenv",
2727
"test": "PATH=$PWD/$npm_package_directories_testnodenv/bin:$PATH bats ${CI:+--tap} test",
28+
"posttest": "npm run lint",
2829
"publish:brew": "brew-publish $npm_package_name v$npm_package_version",
2930
"postversion": "git push --follow-tags && npm run publish:brew"
3031
},

test/test_helper.bash

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# shellcheck shell=bash
2+
13
EXAMPLE_PACKAGE_DIR="$BATS_TMPDIR/example_package"
24
TEST_BASENAME="$(basename "$BATS_TEST_DIRNAME")"
35
# TODO: Should this just be $(dirname ...) ?

0 commit comments

Comments
 (0)