mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-2514][ADF-2517][ADF-2143] Fix build isssues (#3097)
* fix remove angular folder problem * fix npm import cli * fix search module * fix comment * fix tsconfig output * es 20016 tsconfig * travis add demo shell dist * exclude datapicker process services * demo shell script fix * bundle check new build * add simulate publish * invert publish * test distribution * improve sh help * uncomment script * finally got the guilty piece of code * run e2e
This commit is contained in:
@@ -369,4 +369,28 @@ This script test that the update from 2.0.0 to 2.x.x is still smooth
|
||||
|
||||
```sh
|
||||
./test-e2e-bc
|
||||
```
|
||||
|
||||
# simulate-publish.sh
|
||||
|
||||
***simulate-publish.sh***
|
||||
|
||||
This script run a verdaccio server and simulate a publish on it
|
||||
|
||||
## Examples
|
||||
|
||||
```sh
|
||||
./simulate-publish
|
||||
```
|
||||
|
||||
# test-dist.sh
|
||||
|
||||
***test-dist.sh***
|
||||
|
||||
This script test the distribution of ADF against the demo shell
|
||||
|
||||
## Examples
|
||||
|
||||
```sh
|
||||
./test-dist
|
||||
```
|
26
scripts/config/config-verdaccio.yaml
Normal file
26
scripts/config/config-verdaccio.yaml
Normal file
@@ -0,0 +1,26 @@
|
||||
storage: ./.verdaccio_test_env/test-storage
|
||||
|
||||
uplinks:
|
||||
npmjs:
|
||||
url: https://registry.npmjs.org/
|
||||
|
||||
auth:
|
||||
auth-memory:
|
||||
users:
|
||||
test:
|
||||
name: test
|
||||
password: test
|
||||
|
||||
logs:
|
||||
- {type: stdout, format: pretty, level: trace}
|
||||
|
||||
packages:
|
||||
'@*/*':
|
||||
# scoped packages
|
||||
access: $all
|
||||
publish: $anonymous
|
||||
proxy: npmjs
|
||||
'**':
|
||||
access: $all
|
||||
publish: $anonymous
|
||||
proxy: npmjs
|
23
scripts/simulate-publish.sh
Executable file
23
scripts/simulate-publish.sh
Executable file
@@ -0,0 +1,23 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
npm set registry https://registry.npmjs.org/
|
||||
|
||||
echo "====== Install verdaccio ===== "
|
||||
|
||||
npm install -g verdaccio
|
||||
npm install -g concurrently
|
||||
npm install -g verdaccio-auth-memory
|
||||
|
||||
echo "====== Update version ===== "
|
||||
|
||||
$DIR/update-version.sh -nextalpha
|
||||
|
||||
echo "====== Change registry ===== "
|
||||
|
||||
npm set registry http://localhost:4873/
|
||||
|
||||
echo "====== Run verdaccio ===== "
|
||||
|
||||
concurrently "verdaccio --listen 4873 --config $DIR/config/config-verdaccio.yaml" "$DIR/npm-publish.sh"
|
@@ -24,16 +24,16 @@ eval projects=( "@alfresco/core"
|
||||
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 create the disbuild the demo shell in dist mode"
|
||||
echo "-t or -test execute test"
|
||||
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 "-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"
|
||||
}
|
||||
|
44
scripts/test-dist.sh
Executable file
44
scripts/test-dist.sh
Executable file
@@ -0,0 +1,44 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
echo "====== Install demo-shell ===== "
|
||||
|
||||
cd $DIR/../demo-shell
|
||||
npm install
|
||||
|
||||
echo "====== Install lib ===== "
|
||||
|
||||
cd $DIR/../lib
|
||||
npm install
|
||||
|
||||
echo "====== Install JS-API alpha ===== "
|
||||
|
||||
npm install alfresco-js-api@alpha
|
||||
|
||||
echo "====== Build ADF ===== "
|
||||
|
||||
npm run new-build
|
||||
|
||||
echo "====== COPY new build in demo shell node_modules ===== "
|
||||
|
||||
rm -rf ../demo-shell/node_modules/@alfresco
|
||||
|
||||
mkdir -p $DIR/../demo-shell/node_modules/@alfresco/adf-core
|
||||
mkdir -p $DIR/../demo-shell/node_modules/@alfresco/adf-content-services
|
||||
mkdir -p $DIR/../demo-shell/node_modules/@alfresco/adf-process-services
|
||||
mkdir -p $DIR/../demo-shell/node_modules/@alfresco/adf-insights
|
||||
|
||||
cp -R $DIR/../lib/dist/core/* $DIR/../demo-shell/node_modules/@alfresco/adf-core
|
||||
cp -R $DIR/../lib/dist/content-services/* $DIR/../demo-shell/node_modules/@alfresco/adf-content-services
|
||||
cp -R $DIR/../lib/dist/process-services/* $DIR/../demo-shell/node_modules/@alfresco/adf-process-services
|
||||
cp -R $DIR/../lib/dist/insights/* $DIR/../demo-shell/node_modules/@alfresco/adf-insights
|
||||
|
||||
echo "====== Build dist demo shell ===== "
|
||||
|
||||
cd $DIR/../demo-shell
|
||||
npm run build:dist
|
||||
|
||||
echo "====== e2e test ===== "
|
||||
|
||||
npm run e2e
|
Reference in New Issue
Block a user