diff --git a/bin/scripts/prepare.package.sh b/bin/scripts/prepare.package.sh index 72df1c530dc..52b668bc804 100644 --- a/bin/scripts/prepare.package.sh +++ b/bin/scripts/prepare.package.sh @@ -1,5 +1,6 @@ #!/bin/bash DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +VERSION="$(grep -oP 'version:\s*"\K[0-9\.]*' $DIR/../../frontend/express/version.info.js)" echo "Installing prerequisites" apt-get install zip -y @@ -8,7 +9,7 @@ echo "Updating core" git pull echo "Preparing package" -(cd $DIR/../.. ; -zip -r countly.install.zip api bin frontend log plugins supervisor test CHANGELOG Dockerfile Gruntfile.js package.json -x "api/config.js" "api/node_modules/*" "frontend/express/config.js" "frontend/express/public/stylesheets/main.min.css" "frontend/express/public/javascripts/countly/countly.config.js" "frontend/express/public/userimages/*" "frontend/express/certificates/*" "frontend/express/node_modules/*" "log/countly-api.log" "log/countly-dashboard.log" "node_modules/*" "plugins/plugins.json") +(cd $DIR/../../.. ; +zip -r countly-community-edition-v$VERSION.zip countly/ -x "countly/.git/*" "countly/api/config.js" "countly/api/node_modules/*" "countly/frontend/express/config.js" "countly/frontend/express/public/stylesheets/main.min.css" "countly/frontend/express/public/javascripts/countly/countly.config.js" "countly/frontend/express/public/userimages/*" "countly/frontend/express/certificates/*" "countly/frontend/express/node_modules/*" "countly/log/countly-api.log" "countly/log/countly-dashboard.log" "countly/node_modules/*" "countly/plugins/plugins.json") -echo "Install package prepared: $DIR/../../countly.install.zip" +echo "Install package prepared"