2016-11-12 04:27:16 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# Fail the build on any error
|
|
|
|
set -eou pipefail
|
|
|
|
|
|
|
|
# Make sure binary package.json dependencies are available
|
|
|
|
PATH=$(pwd)/node-modules/.bin:$PATH
|
|
|
|
|
|
|
|
echo "--- Check all dependencies in package.json"
|
|
|
|
require-lint --src bin/thumbsup.js --ignore-extra lightgallery
|
|
|
|
|
2016-11-13 02:35:10 +00:00
|
|
|
echo "--- Verify lightgallery dependency is built in"
|
2016-11-12 04:27:16 +00:00
|
|
|
grep \"lightgallery\" package.json 1>/dev/null
|
|
|
|
|
|
|
|
echo "--- Run unit tests"
|
|
|
|
mocha
|
|
|
|
|
|
|
|
echo "--- Update CLI arguments in README"
|
|
|
|
./scripts/readme
|
|
|
|
|
|
|
|
echo "================"
|
|
|
|
echo "Build successful"
|
|
|
|
echo "================"
|