diff --git a/bin/deploy.sh b/bin/deploy.sh index 3c56764..4da17c8 100755 --- a/bin/deploy.sh +++ b/bin/deploy.sh @@ -2,12 +2,7 @@ D="~/rsync/mdr-simulator2/" -rm -rf dist/* -npm run server:build -rm -rf public/* -npm run client:build - -rsync -rvLz -e ssh bin dist node_modules public rob@ccmi.fit.cvut.cz:$D +rsync -rvLz -e ssh bin server node_modules rob@ccmi.fit.cvut.cz:$D #rsync -rvLz -e ssh data rob@ccmi.fit.cvut.cz:$D -rsync -rvLz --ignore-existing -e ssh data rob@ccmi.fit.cvut.cz:$D +#rsync -rvLz --ignore-existing -e ssh data rob@ccmi.fit.cvut.cz:$D diff --git a/package-lock.json b/package-lock.json index ce4f11b..45f7761 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2293,6 +2293,15 @@ "uuid": "^3.3.2" } }, + "webpack-merge": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/webpack-merge/-/webpack-merge-4.2.2.tgz", + "integrity": "sha512-TUE1UGoTX2Cd42j3krGYqObZbOD+xF7u28WB7tfUordytSjbWTIjK/8V0amkBfTYN4/pB/GIDlJZZ657BGG19g==", + "dev": true, + "requires": { + "lodash": "^4.17.15" + } + }, "whatwg-fetch": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-3.0.0.tgz", diff --git a/package.json b/package.json index 1b942d2..3ebc324 100644 --- a/package.json +++ b/package.json @@ -8,8 +8,8 @@ "server:watch": "nodemon --watch shared --watch server/app --ext ts,js,ejs --exec npm run server:build\\;npm run server:run", "server:build": "cd server; rm -rf dist/*; tsc; cp -r app/views dist/", "server:run": "cd server/dist; node server", - "client:watch": "rm -rf server/public/*; webpack --watch --progress", - "client:build": "rm -rf server/public/*; webpack --progress", + "client:watch": "rm -rf server/public/*; webpack --watch --progress --config webpack.dev.js", + "client:build": "rm -rf server/public/*; webpack --progress --config webpack.prod.js", "clean": "npm cache clean --force" }, "devDependencies": { @@ -23,7 +23,8 @@ "@types/proper-lockfile": "^4.1.1", "copy-webpack-plugin": "^5.0.4", "ts-loader": "^6.0.4", - "typescript": "^3.6.2" + "typescript": "^3.6.2", + "webpack-merge": "^4.2.2" }, "repository": { "type": "git", diff --git a/server/app/views/blocks/navbar.ejs b/server/app/views/blocks/navbar.ejs index 710f7df..fb95be7 100644 --- a/server/app/views/blocks/navbar.ejs +++ b/server/app/views/blocks/navbar.ejs @@ -1,5 +1,5 @@