mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-5331] - Alpha ADF/JS-API update has been successfully created. (#6639)
* remove unused script refactor the alpha build to use the JS-API in the branch all the time * use alpha build number * rewire maxretry * Delete check-js-api-version.js
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
## Running a demo project
|
||||
|
||||
|
||||
- [Quick examples](#quick-examples)
|
||||
- [start.sh Demo shell script](#start.sh)
|
||||
- [start demo shell](#Start-Demo-Shell)
|
||||
|
||||
The Alfresco application development framework comes with a demo project that you can run to get a
|
||||
feel of what's available.
|
||||
@@ -14,110 +12,6 @@ feel of what's available.
|
||||
cd scripts
|
||||
```
|
||||
|
||||
# Quick examples developed with ADF
|
||||
|
||||
* Start the demo shell using the JS-API from the development branch and the local component in the lib folder
|
||||
|
||||
```sh
|
||||
./start.sh -dev -gitjsapi development
|
||||
```
|
||||
|
||||
# start.sh
|
||||
|
||||
***start.sh*** script provide an easy way to deal with the npm command and the correct sequence to run the task on demo-shell during development phases.
|
||||
|
||||
## Options
|
||||
|
||||
The default behaviour of the ***start.sh*** script always runs the install and the start of the demo shell on the port 3000, but with some of the options below this behaviour can be changed.
|
||||
All the commands before can be used in combination
|
||||
|
||||
| Option | Description |
|
||||
| --- | --- |
|
||||
| -h or --help | show the help |
|
||||
| -u or --update | run the update of the node_modules packages on the demo shell |
|
||||
| -c or --clean | clean the demo shell folder before starting it |
|
||||
| -t or --test | run the tests on the demo-shell |
|
||||
| --e2e | execute e2e test |
|
||||
| -r or --registry | Start the demo using an alternative npm registry |
|
||||
| -v or --version | Use the version defined in the pacakge.json . Download from npm and Install a different version of the lib (this option is not compatible with -dev) |
|
||||
| -si or --skipinstall | skip the install of the node_modules |
|
||||
| -ss or --skipstart | skip the start of the demo shell and only build it providing a dist folder in the relative demo-shell folder |
|
||||
| -dev or --develop | Start the demo in development mode building the relative folder lib with all the components and pointing to those components instead of the lib present in the node_modules folder |
|
||||
| -dist | Start the demo shell using a light server and the files built in the dist folder, particular useful to test the final result of the project |
|
||||
| -gitjsapi | Start the demo shell using an alfresco-js-api referenced by commit-ish version of the JS-API |
|
||||
| -vjsapi | Use the version defined in the pacakge.json. Download from npm and install a different version of JS-API |
|
||||
|
||||
|
||||
## Examples
|
||||
|
||||
* Start the demo and install all the dependencies
|
||||
|
||||
```sh
|
||||
./start.sh
|
||||
```
|
||||
|
||||
* Start the demo, install all the dependencies, and remove the previous version of the npm packages (*Note. do this only after big changes*):
|
||||
|
||||
```sh
|
||||
./start.sh -c
|
||||
```
|
||||
|
||||
* Start the demo using an alternative npm registry
|
||||
|
||||
```sh
|
||||
./start.sh -registry 'http://npm.local.me:8080/'
|
||||
```
|
||||
|
||||
* Start the demo and update the dependencies:
|
||||
|
||||
```sh
|
||||
./start.sh -update or -u
|
||||
```
|
||||
|
||||
* Use instead the version defined in the pacakge.json. Download from npm and install a different version of the lib (this option is not compatible with -dev) |
|
||||
|
||||
```sh
|
||||
./start.sh -version or -v COMPONENTS_VERSION
|
||||
|
||||
./start.sh -v 1.4.0
|
||||
```
|
||||
|
||||
* Start the demo in development mode building the relative folder lib with all the components and pointing to this component instead of the node_modules one
|
||||
|
||||
```sh
|
||||
./start.sh -develop or -dev
|
||||
```
|
||||
|
||||
* Start the demo shell using a light server using the files built in the dist folder
|
||||
|
||||
```sh
|
||||
./start.sh -dist
|
||||
```
|
||||
|
||||
* Start the demo shell using an alfresco-js-api referenced by commit-ish version of the JS-API
|
||||
|
||||
```sh
|
||||
./start.sh -gitjsapi commit-ish
|
||||
|
||||
./start.sh -gitjsapi development
|
||||
|
||||
./start.sh -gitjsapi de92be966e2ce7eca642ca9e9d7647ba4f849356
|
||||
```
|
||||
|
||||
* Start the alfresco-js-api against a commit-ish version of the JS-API
|
||||
|
||||
```sh
|
||||
./start.sh -vjsapi 1.4.0
|
||||
|
||||
```
|
||||
|
||||
* Run the Demo shell tests
|
||||
|
||||
```sh
|
||||
./start.sh -t
|
||||
|
||||
```
|
||||
|
||||
***npm-check-bundles.sh*** check the bundles in the package npm are present
|
||||
|
||||
## Options
|
||||
|
@@ -1,106 +0,0 @@
|
||||
let alfrescoApi = require('@alfresco/js-api');
|
||||
let program = require('commander');
|
||||
|
||||
async function main() {
|
||||
|
||||
program
|
||||
.version('0.1.0')
|
||||
.option('--host [type]', 'Remote environment host adf.lab.com ')
|
||||
.option('-p, --password [type]', 'password RANCHER')
|
||||
.option('-u, --username [type]', 'username RANCHER')
|
||||
.parse(process.argv);
|
||||
|
||||
const alfrescoJsApi = new alfrescoApi.AlfrescoApiCompatibility({
|
||||
provider: 'ECM',
|
||||
hostEcm: program.host
|
||||
});
|
||||
|
||||
try {
|
||||
await alfrescoJsApi.login(program.username, program.password);
|
||||
} catch (error) {
|
||||
console.log(JSON.stringify(error));
|
||||
}
|
||||
|
||||
console.log('====== Clean Root ======');
|
||||
await cleanRoot(alfrescoJsApi);
|
||||
|
||||
console.log('====== Clean Sites ======');
|
||||
await deleteSite(alfrescoJsApi);
|
||||
|
||||
console.log('====== Empty Trash ======');
|
||||
await emptyTrashCan(alfrescoJsApi);
|
||||
}
|
||||
|
||||
async function cleanRoot(alfrescoJsApi) {
|
||||
|
||||
let rootNodes = await alfrescoJsApi.core.nodesApi.getNodeChildren('-root-', {
|
||||
include: ['properties']
|
||||
});
|
||||
|
||||
for (let i = 0; i < rootNodes.list.entries.length; i++) {
|
||||
|
||||
sleep(200);
|
||||
|
||||
if (rootNodes.list.entries[i].entry.createdByUser.id !== 'System') {
|
||||
|
||||
try {
|
||||
await alfrescoJsApi.core.nodesApi.deleteNode(rootNodes.list.entries[i].entry.id);
|
||||
} catch (error) {
|
||||
console.log('error' + JSON.stringify(error));
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
async function emptyTrashCan(alfrescoJsApi) {
|
||||
let deletedNodes = await alfrescoJsApi.core.nodesApi.getDeletedNodes();
|
||||
|
||||
if (deletedNodes.list.entries.length > 0) {
|
||||
for (let i = 0; i < deletedNodes.list.entries.length; i++) {
|
||||
|
||||
sleep(200);
|
||||
|
||||
console.log(deletedNodes.list.entries[i].entry.id);
|
||||
|
||||
try {
|
||||
await alfrescoJsApi.core.nodesApi.purgeDeletedNode(deletedNodes.list.entries[i].entry.id);
|
||||
} catch (error) {
|
||||
console.log('error' + JSON.stringify(error));
|
||||
}
|
||||
}
|
||||
|
||||
emptyTrashCan(alfrescoJsApi);
|
||||
}
|
||||
}
|
||||
|
||||
async function deleteSite(alfrescoJsApi) {
|
||||
let listSites = alfrescoJsApi.core.sitesApi.getSites();
|
||||
|
||||
if (listSites.list.pagination.totalItems > 1) {
|
||||
for (let i = 0; i < listSites.list.entries.length; i++) {
|
||||
|
||||
sleep(200);
|
||||
|
||||
console.log(listSites.list.entries[i].entry.id);
|
||||
|
||||
if (listSites.list.entries[i].entry.id !== 'swsdp') {
|
||||
try {
|
||||
await alfrescoJsApi.core.sitesApi.deleteSite(listSites.list.entries[i].entry.id, {options: {permanent: true}});
|
||||
} catch (error) {
|
||||
console.log('error' + JSON.stringify(error));
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
deleteSite(alfrescoJsApi);
|
||||
}
|
||||
}
|
||||
|
||||
function sleep(delay) {
|
||||
var start = new Date().getTime();
|
||||
while (new Date().getTime() < start + delay) ;
|
||||
}
|
||||
|
||||
main();
|
@@ -78,8 +78,7 @@ fi
|
||||
|
||||
if [[ "${EXEC_ALPHA}" == true ]]
|
||||
then
|
||||
ISH_KEY=$(git rev-parse HEAD)
|
||||
NEXT_VERSION=${NEXT_VERSION}-${ISH_KEY}
|
||||
NEXT_VERSION=${NEXT_VERSION}-${TRAVIS_BUILD_NUMBER}
|
||||
fi
|
||||
|
||||
if [[ "${EXEC_BETA}" == true ]]
|
||||
|
@@ -1,44 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
eval projects=(
|
||||
"@alfresco/adf-cli"
|
||||
"@alfresco/adf-core"
|
||||
"@alfresco/adf-content-services"
|
||||
"@alfresco/adf-insights"
|
||||
"@alfresco/adf-process-services"
|
||||
"@alfresco/adf-process-services-cloud"
|
||||
"@alfresco/adf-testing"
|
||||
"@alfresco/adf-extensions" )
|
||||
|
||||
show_help() {
|
||||
echo "Usage: npm-move-tag.sh"
|
||||
echo ""
|
||||
echo "-v version package to apply new tag"
|
||||
echo "-t new tag name to add"
|
||||
}
|
||||
|
||||
new_tag(){
|
||||
eval TAG=$1
|
||||
}
|
||||
|
||||
package_version(){
|
||||
eval PACKAGE_VERSION=$1
|
||||
}
|
||||
|
||||
while [[ $1 == -* ]]; do
|
||||
case "$1" in
|
||||
-h|--help|-\?) show_help; exit 0;;
|
||||
-t|--tag) new_tag $2; shift 2;;
|
||||
-v) package_version $2; shift 2;;
|
||||
-*) echo "invalid option: $1" 1>&2; show_help; exit 0;;
|
||||
esac
|
||||
done
|
||||
|
||||
for PACKAGE in ${projects[@]}
|
||||
do
|
||||
echo "====== Move ${PACKAGE}@${PACKAGE_VERSION} to tag ${TAG}===== "
|
||||
echo "====== command npm dist-tag add ${PACKAGE}@${PACKAGE_VERSION} ${TAG}===== "
|
||||
npm dist-tag add ${PACKAGE}@${PACKAGE_VERSION} ${TAG}
|
||||
done
|
199
scripts/start.sh
199
scripts/start.sh
@@ -1,199 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
eval EXEC_INSTALL=false
|
||||
eval EXEC_UPDATE=false
|
||||
eval EXEC_CLEAN=false
|
||||
eval EXEC_DEVELOP=false
|
||||
eval EXEC_VERSION=false
|
||||
eval EXEC_DIST=false
|
||||
eval EXEC_GIT_NPM_INSTALL_JSAPI=false
|
||||
eval EXEC_VERSION_JSAPI=false
|
||||
eval EXEC_START=true
|
||||
eval EXEC_TEST=false
|
||||
eval EXEC_E2E=false
|
||||
eval JSAPI_VERSION=""
|
||||
eval NG2_COMPONENTS_VERSION=""
|
||||
eval GIT_ISH=""
|
||||
|
||||
eval projects=( "@alfresco/core"
|
||||
"@alfresco/content-service"
|
||||
"@alfresco/process-service"
|
||||
"@alfresco/process-service-cloud"
|
||||
"@alfresco/extensions" )
|
||||
|
||||
show_help() {
|
||||
echo "Usage: start.sh"
|
||||
echo ""
|
||||
echo "-ss or --skipstart build only the demo shell without start"
|
||||
echo "-si or --skipinstall start the demo shell and skip the install the dependencies"
|
||||
echo "-dev or --develop start the demo shell using the relative lib folder to link the components"
|
||||
echo "-dist build or start the demo shell in dist mode"
|
||||
echo "-t or --test execute test"
|
||||
echo "--e2e execute e2e test"
|
||||
echo "-u or --update start the demo shell and update the dependencies"
|
||||
echo "-c or --clean clean the demo shell and reinstall the dependencies"
|
||||
echo "-r or --registry to download the packages from an alternative npm registry example -registry 'http://npm.local.me:8080/' "
|
||||
echo "-v or --version install different version of ng2_components from npm defined in the package.json this option is not compatible with -d"
|
||||
echo "-gitjsapi to build all the components against a commit-ish version of the JS-API"
|
||||
echo "-vjsapi install different version from npm of JS-API defined in the package.json"
|
||||
}
|
||||
|
||||
install() {
|
||||
EXEC_INSTALL=false
|
||||
}
|
||||
|
||||
update() {
|
||||
EXEC_UPDATE=true
|
||||
}
|
||||
|
||||
develop() {
|
||||
EXEC_DEVELOP=true
|
||||
}
|
||||
|
||||
enable_dist() {
|
||||
EXEC_DIST=true
|
||||
}
|
||||
|
||||
disable_start() {
|
||||
EXEC_START=false
|
||||
}
|
||||
|
||||
enable_test() {
|
||||
EXEC_TEST=true
|
||||
}
|
||||
|
||||
enable_e2e() {
|
||||
EXEC_E2E=true
|
||||
}
|
||||
|
||||
enable_js_api_git_link() {
|
||||
GIT_ISH='git+https://github.com/Alfresco/alfresco-js-api.git#'$1
|
||||
EXEC_GIT_NPM_INSTALL_JSAPI=true
|
||||
}
|
||||
|
||||
version_component() {
|
||||
NG2_COMPONENTS_VERSION=$1
|
||||
|
||||
if [[ "${NG2_COMPONENTS_VERSION}" == "" ]]
|
||||
then
|
||||
echo "NG2 components version required with -v | -version"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
EXEC_VERSION=true
|
||||
}
|
||||
|
||||
version_js_api() {
|
||||
JSAPI_VERSION=$1
|
||||
|
||||
if [[ "${JSAPI_VERSION}" == "" ]]
|
||||
then
|
||||
echo "JSAPI version required with -vJSApi"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
EXEC_VERSION_JSAPI=true
|
||||
}
|
||||
|
||||
change_registry(){
|
||||
NPM_REGISTRY=$1
|
||||
|
||||
if [[ "${NPM_REGISTRY}" == "" ]]
|
||||
then
|
||||
echo "NPM registry required WITH OPTION -r | -registry"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "====== CHANGE REGISTRY: ${NPM_REGISTRY} ====="
|
||||
npm config set registry ${NPM_REGISTRY}
|
||||
}
|
||||
|
||||
clean() {
|
||||
EXEC_CLEAN=true
|
||||
EXEC_INSTALL=true
|
||||
}
|
||||
|
||||
while [[ $1 == -* ]]; do
|
||||
case "$1" in
|
||||
-h|--help|-\?) show_help; exit 0;;
|
||||
-u|--update) update; shift;;
|
||||
-c|--clean) clean; shift;;
|
||||
-t|--test) enable_test; shift;;
|
||||
--e2e) enable_e2e; shift;;
|
||||
-r|--registry) change_registry $2; shift 2;;
|
||||
-v|--version) version_component $2; shift 2;;
|
||||
-si|--skipinstall) install; shift;;
|
||||
-ss|--skipstart) disable_start; shift;;
|
||||
-dev|--develop) develop; shift;;
|
||||
-dist) enable_dist; shift;;
|
||||
-gitjsapi) enable_js_api_git_link $2; shift 2;;
|
||||
-vjsapi) version_js_api $2; shift 2;;
|
||||
-*) echo "invalid option: $1" 1>&2; show_help; exit 0;;
|
||||
esac
|
||||
done
|
||||
|
||||
cd "$DIR/.."
|
||||
|
||||
if $EXEC_CLEAN == true; then
|
||||
echo "====== Clean Demo shell ====="
|
||||
npm install rimraf
|
||||
npm run clean
|
||||
fi
|
||||
|
||||
if $EXEC_INSTALL == true; then
|
||||
echo "====== Install Demo shell ====="
|
||||
npm install
|
||||
fi
|
||||
|
||||
if $EXEC_VERSION == true; then
|
||||
echo "====== Install version "${NG2_COMPONENTS_VERSION}" of components ====="
|
||||
|
||||
if [[ "${EXEC_DEVELOP}" == "" ]]
|
||||
then
|
||||
echo "Option -v is not compatible with -d see the help"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
for PACKAGE in ${projects[@]}
|
||||
do
|
||||
npm install ${PACKAGE}@${NG2_COMPONENTS_VERSION}
|
||||
done
|
||||
fi
|
||||
|
||||
if $EXEC_GIT_NPM_INSTALL_JSAPI == true; then
|
||||
echo "====== Use the alfresco JS-API '$GIT_ISH'====="
|
||||
npm install $GIT_ISH --no-save
|
||||
cd "$DIR/../demo-shell/node_modules/alfresco-js-api"
|
||||
npm install
|
||||
fi
|
||||
|
||||
if $EXEC_VERSION_JSAPI == true; then
|
||||
echo "====== Use the alfresco JS-API '$JSAPI_VERSION'====="
|
||||
npm install alfresco-js-api@${JSAPI_VERSION}
|
||||
fi
|
||||
|
||||
if [ -f "./.env" ]; then
|
||||
export $(cat .env | xargs)
|
||||
fi
|
||||
|
||||
if $EXEC_START == true; then
|
||||
if $EXEC_DIST == true; then
|
||||
echo "====== Start Demo shell dist mode ====="
|
||||
npm run start:prod
|
||||
else
|
||||
echo "====== Start Demo shell ====="
|
||||
npm run start
|
||||
fi
|
||||
else
|
||||
if $EXEC_DEVELOP == true; then
|
||||
echo "====== Build Demo shell dev mode ====="
|
||||
npm run build
|
||||
else
|
||||
echo "====== Build Demo shell ====="
|
||||
npm run build:prod
|
||||
fi
|
||||
fi
|
||||
|
||||
|
@@ -6,7 +6,6 @@ BROWSER_RUN=false
|
||||
DEVELOPMENT=false
|
||||
LITESERVER=false
|
||||
EXEC_VERSION_JSAPI=false
|
||||
TIMEOUT=120000
|
||||
DEBUG=false
|
||||
|
||||
show_help() {
|
||||
@@ -26,12 +25,10 @@ show_help() {
|
||||
echo "-host or --host URL of the Front end to test"
|
||||
echo "-host_sso the entire path including the name of the realm"
|
||||
echo "-save save the error screenshot and report in the remote env"
|
||||
echo "-timeout or --timeout override the timeout foe the wait utils"
|
||||
echo "-m --maxInstances max instances parallel for tests"
|
||||
echo "-log or --log print all the browser log"
|
||||
echo "-db or --debug run the debugger"
|
||||
echo "-ud run dist"
|
||||
echo "-vjsapi install different version from npm of JS-API defined in the package.json"
|
||||
echo "-h or --help"
|
||||
}
|
||||
|
||||
@@ -82,10 +79,6 @@ set_proxy(){
|
||||
export PROXY_HOST_ADF=$PROXY
|
||||
}
|
||||
|
||||
set_timeout(){
|
||||
TIMEOUT=$1
|
||||
}
|
||||
|
||||
set_save_screenshot(){
|
||||
mkdir -p ./e2e-output/junit-report
|
||||
export SAVE_SCREENSHOT=true
|
||||
@@ -126,18 +119,6 @@ max_instances(){
|
||||
export MAXINSTANCES=$1
|
||||
}
|
||||
|
||||
version_js_api() {
|
||||
JSAPI_VERSION=$1
|
||||
|
||||
if [[ "${JSAPI_VERSION}" == "" ]]
|
||||
then
|
||||
echo "JSAPI version required with -vJSApi"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
EXEC_VERSION_JSAPI=true
|
||||
}
|
||||
|
||||
while [[ $1 == -* ]]; do
|
||||
case "$1" in
|
||||
-h|--help|-\?) show_help; exit 0;;
|
||||
@@ -146,7 +127,6 @@ while [[ $1 == -* ]]; do
|
||||
-identity_admin_email) set_identity_admin_email $2; shift 2;;
|
||||
-identity_admin_password) set_identity_admin_password $2; shift 2;;
|
||||
-f|--folder) set_test_folder $2; shift 2;;
|
||||
-timeout|--timeout) set_timeout $2; shift 2;;
|
||||
-b|--browser) set_browser; shift;;
|
||||
-env|--env) set_env $2; shift 2;;
|
||||
-dev|--dev) set_development; shift;;
|
||||
@@ -161,7 +141,6 @@ while [[ $1 == -* ]]; do
|
||||
-log|--log) set_log; shift ;;
|
||||
-host_sso|--host_sso) set_host_sso $2; shift 2;;
|
||||
-m|--maxInstances) max_instances $2; shift 2;;
|
||||
-vjsapi) version_js_api $2; shift 2;;
|
||||
-*) echo "invalid option: $1" 1>&2; show_help; exit 1;;
|
||||
esac
|
||||
done
|
||||
@@ -169,13 +148,6 @@ done
|
||||
rm -rf ./e2e/downloads/
|
||||
rm -rf ./e2e-output/
|
||||
|
||||
export TIMEOUT=$TIMEOUT
|
||||
|
||||
if $EXEC_VERSION_JSAPI == true; then
|
||||
echo "====== Use the alfresco JS-API '$JSAPI_VERSION'====="
|
||||
npm install alfresco-js-api@${JSAPI_VERSION}
|
||||
fi
|
||||
|
||||
echo "====== Update webdriver-manager ====="
|
||||
if [ "$CI" = "true" ]; then
|
||||
export chrome=$(google-chrome --product-version)
|
||||
|
@@ -25,11 +25,6 @@ then
|
||||
node ./scripts/pre-publish.js
|
||||
|
||||
npm install
|
||||
else
|
||||
echo "====== Update the package.json with latest JS-API/CLI deps ====="
|
||||
npx @alfresco/adf-cli@alpha update-version --alpha --pathPackage "$(pwd)"
|
||||
npm install;
|
||||
# nx affected --target=build --base=$BASE_HASH --head=$HEAD_HASH --exclude="cli,demoshell" --prod --with-deps || exit 1; TODO comment out when affected is fixe
|
||||
fi;
|
||||
|
||||
./scripts/build/build-all-lib.sh
|
||||
|
@@ -26,9 +26,7 @@ projectslength=${#projects[@]}
|
||||
show_help() {
|
||||
echo "Usage: update-version.sh"
|
||||
echo ""
|
||||
echo "-sj or -sjsapi don't update js-api version"
|
||||
echo "-vj or -versionjsapi to use a different version of js-api"
|
||||
echo "-components execute the change version only in the components "
|
||||
echo "-v or -version version to update"
|
||||
echo "-major increase the major number and reset minor and patch"
|
||||
echo "-minor increase the minor number and reset the patch number"
|
||||
@@ -40,22 +38,12 @@ show_help() {
|
||||
echo "-gnu for gnu"
|
||||
}
|
||||
|
||||
skip_js() {
|
||||
echo "====== Skip JS-API change version $1 ====="
|
||||
JS_API=false
|
||||
}
|
||||
|
||||
last_alpha_mode() {
|
||||
length=`expr $projectslength - 1`
|
||||
echo "====== Auto find last ALPHA version of ${projects[${length}]} ====="
|
||||
VERSION=$(npm view @alfresco/adf-${projects[${length}]}@alpha version)
|
||||
|
||||
echo "====== version lib ${VERSION} ====="
|
||||
|
||||
DIFFERENT_JS_API=true
|
||||
VERSION_JS_API=$(npm view @alfresco/js-api@alpha version)
|
||||
|
||||
echo "====== version js-api ${DIFFERENT_JS_API} ====="
|
||||
}
|
||||
|
||||
next_alpha_mode() {
|
||||
@@ -63,11 +51,7 @@ next_alpha_mode() {
|
||||
VERSION=$(./next_version.sh -${SEMANTIC} -alpha)
|
||||
|
||||
echo "====== version lib ${VERSION} ====="
|
||||
|
||||
DIFFERENT_JS_API=true
|
||||
VERSION_JS_API=$(npm view @alfresco/js-api@alpha version)
|
||||
|
||||
echo "====== version js-api ${DIFFERENT_JS_API} ====="
|
||||
JS_API=false
|
||||
}
|
||||
|
||||
next_beta_mode() {
|
||||
@@ -75,11 +59,7 @@ next_beta_mode() {
|
||||
VERSION=$(./next_version.sh -${SEMANTIC} -beta)
|
||||
|
||||
echo "====== version lib ${VERSION} ====="
|
||||
|
||||
DIFFERENT_JS_API=true
|
||||
VERSION_JS_API=$(npm view @alfresco/js-api@alpha version)
|
||||
|
||||
echo "====== version js-api ${DIFFERENT_JS_API} ====="
|
||||
JS_API=false
|
||||
}
|
||||
|
||||
last_beta_mode() {
|
||||
@@ -115,12 +95,6 @@ version_js_change() {
|
||||
DIFFERENT_JS_API=true
|
||||
}
|
||||
|
||||
only_components() {
|
||||
echo "====== UPDATE Only the components ====="
|
||||
TOTAL_BUILD=false
|
||||
}
|
||||
|
||||
|
||||
update_component_version() {
|
||||
echo "====== UPDATE PACKAGE VERSION of ${PACKAGE} to ${VERSION} version in all the package.json ======"
|
||||
DESTDIR="$DIR/../lib/${1}"
|
||||
@@ -201,7 +175,6 @@ while [[ $1 == -* ]]; do
|
||||
-nextalpha) next_alpha_mode; shift;;
|
||||
-beta) last_beta_mode; shift;;
|
||||
-nextbeta) next_beta_mode; shift;;
|
||||
-components) only_components; shift;;
|
||||
-*) shift;;
|
||||
esac
|
||||
done
|
||||
@@ -240,11 +213,7 @@ do
|
||||
fi
|
||||
done
|
||||
|
||||
if $TOTAL_BUILD; then
|
||||
echo "====== UPDATE TOTAL BUILD======"
|
||||
|
||||
update_total_build_dependency_version
|
||||
fi
|
||||
update_total_build_dependency_version
|
||||
|
||||
if $JS_API == true; then
|
||||
if $DIFFERENT_JS_API == true; then
|
||||
|
Reference in New Issue
Block a user