Add ability to build client with source maps
This commit is contained in:
parent
69eddafb17
commit
29f148a613
2 changed files with 7 additions and 2 deletions
|
@ -43,7 +43,12 @@ rm -rf ./dist ./compiled
|
|||
|
||||
# Don't build other languages if --light arg is provided
|
||||
if [ -z ${1+x} ] || ([ "$1" != "--light" ] && [ "$1" != "--analyze-bundle" ]); then
|
||||
npm run ng build -- --prod --output-path "dist/build"
|
||||
additionalParams=""
|
||||
if [ ! -z ${1+x} ] && [ "$1" == "--source-map" ]; then
|
||||
additionalParams="--sourceMap=true"
|
||||
fi
|
||||
|
||||
npm run ng build -- --prod --output-path "dist/build" $additionalParams
|
||||
|
||||
for key in "${!languages[@]}"; do
|
||||
lang=${languages[$key]}
|
||||
|
|
|
@ -18,7 +18,7 @@ today=$(date '+%F')
|
|||
directory_name="peertube-nightly-$today"
|
||||
tar_name="peertube-nightly-$today.tar.xz"
|
||||
|
||||
npm run build
|
||||
npm run build -- --source-map
|
||||
|
||||
nightly_version="nightly-$today"
|
||||
sed -i 's/"version": "\([^"]\+\)"/"version": "\1-'"$nightly_version"'"/' ./package.json
|
||||
|
|
Loading…
Reference in a new issue