Skip to content

Commit

Permalink
PI projects npm behaviour consolidation (#25)
Browse files Browse the repository at this point in the history
* added purge action before all install action to allow for npm behaviour to be as legacy behaviour to not cause incompabilities when installing with npm ci

* bump version
  • Loading branch information
joaoagoncalves authored and jpsfs committed Dec 24, 2019
1 parent ec67c28 commit 234d653
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions generators/application/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ export = class extends HtmlGenerator {

install() {
// Install the web
this.spawnCommandSync('gulp', ['purge']);
this.spawnCommandSync('gulp', ['install']);

// Try to populate settings
Expand Down
1 change: 1 addition & 0 deletions generators/converter/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export = class extends HtmlGenerator {
install() {
this.destinationRoot(this.packageFolder);
if (this.shouldInstall) {
this.spawnCommandSync('gulp', ['purge']);
this.spawnCommandSync('gulp', ['install']);
}
this.spawnCommandSync('gulp', ['build']);
Expand Down
1 change: 1 addition & 0 deletions generators/dataSource/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ export = class extends HtmlGenerator {
install() {
this.destinationRoot(this.packageFolder);
if (this.shouldInstall) {
this.spawnCommandSync('gulp', ['purge']);
this.spawnCommandSync('gulp', ['install']);
}
this.spawnCommandSync('gulp', ['build']);
Expand Down
1 change: 1 addition & 0 deletions generators/executionView/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ export = class extends HtmlGenerator {
install() {
this.destinationRoot(this.packageFolder);
if (this.shouldInstall) {
this.spawnCommandSync('gulp', ['purge']);
this.spawnCommandSync('gulp', ['install']);
}
this.spawnCommandSync('gulp', ['build']);
Expand Down
2 changes: 2 additions & 0 deletions generators/html.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,13 @@ export class HtmlGenerator extends Generator {

// Install in the package
this.destinationRoot(packagePath);
this.spawnCommandSync('gulp', ['purge']);
let ls = this.spawnCommandSync('gulp', ['install']);

// Install in all apps
this.webAppFoldersPath.forEach((appFolderPath) => {
this.destinationRoot(appFolderPath);
this.spawnCommandSync('gulp', ['purge']);
this.spawnCommandSync('gulp', ['install']);
});

Expand Down
1 change: 1 addition & 0 deletions generators/widget/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ export = class extends HtmlGenerator {
install() {
this.destinationRoot(this.packageFolder);
if (this.shouldInstall) {
this.spawnCommandSync('gulp', ['purge']);
this.spawnCommandSync('gulp', ['install']);
}
this.spawnCommandSync('gulp', ['build']);
Expand Down
1 change: 1 addition & 0 deletions generators/wizard/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ export = class extends HtmlGenerator {
install() {
this.destinationRoot(this.packageFolder);
if (this.shouldInstall) {
this.spawnCommandSync('gulp', ['purge']);
this.spawnCommandSync('gulp', ['install']);
}
this.spawnCommandSync('gulp', ['build']);
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@criticalmanufacturing/generator-html",
"version": "7.1.0-3",
"version": "7.1.0-4",
"description": "CMF HTML GUI Scaffolding",
"files": [
"generators/*.js",
Expand Down

0 comments on commit 234d653

Please sign in to comment.