mirror of
https://gitlab.nic.cz/turris/reforis/foris-js.git
synced 2025-06-14 13:36:33 +02:00
Flat structure of published package
This commit is contained in:
9
scripts/collect_files.sh
Normal file
9
scripts/collect_files.sh
Normal file
@ -0,0 +1,9 @@
|
||||
#!/bin/sh
|
||||
|
||||
# Collect files
|
||||
npm run build
|
||||
cp package.json dist
|
||||
cp -rf translations dist
|
||||
# Remove unwanted files
|
||||
rm -rf dist/**/__tests__
|
||||
rm -rf dist/__mocks__
|
@ -12,10 +12,10 @@ else
|
||||
then
|
||||
BETA_VERSION=$(npx -c 'echo "$npm_package_version"')-beta.$CI_COMMIT_SHORT_SHA
|
||||
npm version "$BETA_VERSION" --git-tag-version false
|
||||
npm publish --tag beta
|
||||
cd dist && npm publish --tag beta
|
||||
elif test "$1" = "latest"
|
||||
then
|
||||
npm publish
|
||||
cd dist && npm publish
|
||||
else
|
||||
echo "Usage: publish.sh [ beta | latest ]"
|
||||
exit 1
|
||||
|
Reference in New Issue
Block a user