Fix travis build

This commit is contained in:
uwap 2018-02-02 08:00:56 +01:00
parent c7ca716802
commit f70f2977ab
3 changed files with 9 additions and 2 deletions

View file

@ -7,7 +7,7 @@
"build": "webpack --bail --config webpack.dev.js --env",
"production-build": "webpack --bail --config webpack.prod.js --env",
"watch": "webpack-dev-server --open --config webpack.dev.js --env",
"travis": "yarn lint && yarn build && yarn production-build",
"travis": "./travis.sh",
"lint": "eslint -- --ext js --ext jsx src/",
"precommit": "yarn lint"
},

7
travis.sh Executable file
View file

@ -0,0 +1,7 @@
#!/bin/sh
yarn lint && for conf in $(ls config/); do
if [ $conf == "utils.js" ]; then
continue
fi
yarn build $conf && yarn production-build $conf
done || exit 1

View file

@ -25,7 +25,7 @@ const configPath = env => {
module.exports = env => merge(common, {
entry: {
main: [configPath(env),
path.resolve(__dirname, 'src/index.jsx')]
path.resolve(__dirname, 'src/index.jsx')],
vendor: ['react', 'material-ui', 'mqtt', 'lodash']
},
module: {