fix build cli

This commit is contained in:
Eugenio Romano
2019-06-07 10:46:27 +01:00
parent 7a3e2932bb
commit 8a2a71d60b
4 changed files with 37 additions and 14 deletions

11
lib/cli/.npmignore Normal file
View File

@@ -0,0 +1,11 @@
npm-debug.log
.idea
.npmrc
/.editorconfig
/.travis.yml
/*.json
/.npmignore
node_modules

View File

@@ -11,32 +11,32 @@ var program = require('commander');
var templatePath = path.resolve(__dirname, 'templates', 'licensePage.ejs'); var templatePath = path.resolve(__dirname, 'templates', 'licensePage.ejs');
const nonStandardLicenses = { const nonStandardLicenses = {
"public domain": "PDDL-1.0", 'public domain': 'PDDL-1.0',
"apache": "Apache-2.0", 'apache': 'Apache-2.0',
"bsd": "BSD-2-Clause" 'bsd': 'BSD-2-Clause'
}; };
const missingRepos = { const missingRepos = {
"@alfresco/adf-testing": "https://github.com/Alfresco/alfresco-ng2-components", '@alfresco/adf-testing': 'https://github.com/Alfresco/alfresco-ng2-components',
"@webassemblyjs/helper-api-error": "https://github.com/xtuc/webassemblyjs", '@webassemblyjs/helper-api-error': 'https://github.com/xtuc/webassemblyjs',
"@webassemblyjs/helper-fsm": "https://github.com/xtuc/webassemblyjs", '@webassemblyjs/helper-fsm': 'https://github.com/xtuc/webassemblyjs',
"@webassemblyjs/ieee754": "https://github.com/xtuc/webassemblyjs", '@webassemblyjs/ieee754': 'https://github.com/xtuc/webassemblyjs',
"@webassemblyjs/leb128": "https://github.com/xtuc/webassemblyjs", '@webassemblyjs/leb128': 'https://github.com/xtuc/webassemblyjs',
"adf-tslint-rules": "https://github.com/Alfresco/alfresco-ng2-components", 'adf-tslint-rules': 'https://github.com/Alfresco/alfresco-ng2-components',
"adf-monaco-extension": "https://github.com/eromano/aca-monaco-extension", 'adf-monaco-extension': 'https://github.com/eromano/aca-monaco-extension',
"indexof": "https://github.com/component/indexof", 'indexof': 'https://github.com/component/indexof',
"rxjs-compat": "https://github.com/ReactiveX/rxjs/tree/master/compat", 'rxjs-compat': 'https://github.com/ReactiveX/rxjs/tree/master/compat',
}; };
program program
.usage('<versionNumber>') .usage('<versionNumber>')
.parse(process.argv); .parse(process.argv);
var packageJson = JSON.parse(fs.readFileSync(path.resolve('./','package.json')), 'utf8'); var packageJson = JSON.parse(fs.readFileSync(path.resolve('./','package.json')));
if (!packageJson) { if (!packageJson) {
console.error('Move in the path where you have the package.json'); console.error('Move in the path where you have the package.json');
return; throw '';
} }
console.log(path.resolve('./','package.json')); console.log(path.resolve('./','package.json'));

View File

@@ -27,6 +27,9 @@ echo "====== Run process-services-cloud ====="
echo "====== Run testing =====" echo "====== Run testing ====="
./build-testing.sh ./build-testing.sh
echo "====== Run Cli ====="
./build-cli.sh
echo "====== Copy schema =====" echo "====== Copy schema ====="
cp ../../lib/core/app-config/schema.json ../../lib/dist/core/app.config.schema.json cp ../../lib/core/app-config/schema.json ../../lib/dist/core/app.config.schema.json

9
scripts/build/build-cli.sh Executable file
View File

@@ -0,0 +1,9 @@
#!/usr/bin/env bash
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
cd $DIR/../..
echo "====== Cli ======"
echo "====== Build ======"
cp -R ./lib/cli/ lib/dist/cli/