Skip to content

Commit 02979e1

Browse files
Hristo HristovHristo Hristov
authored andcommitted
fix(cli): add generate deployment script property in yaml files
1 parent f58f543 commit 02979e1

File tree

10 files changed

+14
-10
lines changed

10 files changed

+14
-10
lines changed

packages/cli/templates/react/igr-ts/projects/_base/files/__dot__github/workflows/github-pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88

99
jobs:
1010
build-and-deploy:
11-
if: ${{ vars.PAGES_DEPLOYMENT == 'Always' || (vars.PAGES_DEPLOYMENT == 'Default' && github.ref_name == github.event.repository.default_branch) }}
11+
if: $(yamlGenerateDeploymentScript) == true
1212
runs-on: ubuntu-latest
1313

1414
permissions:

packages/cli/templates/react/igr-ts/projects/_base/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ export class BaseIgrTsProject implements ProjectTemplate {
4242
"dot": ".",
4343
"path": name,
4444
"projectTemplate": this.id,
45-
"yamlDefaultBranch": this.id === "base" ? "<%=yaml-default-branch%>" : "main"
45+
"yamlDefaultBranch": this.id === "base" ? "<%=yaml-default-branch%>" : "main",
46+
"yamlGenerateDeploymentScript": "<%=yaml-generate-deployment-script%>"
4647
};
4748
}
4849
}

packages/cli/templates/webcomponents/igc-ts/projects/_base/files/__dot__github/workflows/github-pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88

99
jobs:
1010
build-and-deploy:
11-
if: ${{ vars.PAGES_DEPLOYMENT == 'Always' || (vars.PAGES_DEPLOYMENT == 'Default' && github.ref_name == github.event.repository.default_branch) }}
11+
if: $(yamlGenerateDeploymentScript) == true
1212
runs-on: ubuntu-latest
1313

1414
permissions:

packages/cli/templates/webcomponents/igc-ts/projects/_base/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ export class BaseIgcProject implements ProjectTemplate {
3737
dot: ".",
3838
path: name,
3939
projectTemplate: this.id,
40-
yamlDefaultBranch: this.id === "base" ? "<%=yaml-default-branch%>" : "main"
40+
yamlDefaultBranch: this.id === "base" ? "<%=yaml-default-branch%>" : "main",
41+
yamlGenerateDeploymentScript: "<%=yaml-generate-deployment-script%>"
4142
};
4243

4344
return config;

packages/igx-templates/igx-ts-legacy/projects/_base/files/__dot__github/workflows/github-pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88

99
jobs:
1010
build-and-deploy:
11-
if: ${{ vars.PAGES_DEPLOYMENT == 'Always' || (vars.PAGES_DEPLOYMENT == 'Default' && github.ref_name == github.event.repository.default_branch) }}
11+
if: <%=yamlGenerateDeploymentScript%> == true
1212
runs-on: ubuntu-latest
1313

1414
permissions:

packages/igx-templates/igx-ts-legacy/projects/_base/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,8 @@ $app-palette: palette($primary, $secondary, $surface);
6666
path: name,
6767
projectTemplate: this.id,
6868
yamlDefaultBranch: "<%=yaml-default-branch%>", // the placeholder will be evaluated by CodeGen
69-
ApplicationTitle: "<%=ApplicationTitle%>" // the placeholder will be evaluated by CodeGen
69+
ApplicationTitle: "<%=ApplicationTitle%>", // the placeholder will be evaluated by CodeGen
70+
yamlGenerateDeploymentScript: "<%=yaml-generate-deployment-script%>" // the placeholder will be evaluated by CodeGen
7071
};
7172

7273
switch (theme) {

packages/igx-templates/igx-ts-legacy/projects/_base_with_home/files/__dot__github/workflows/github-pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88

99
jobs:
1010
build-and-deploy:
11-
if: ${{ vars.PAGES_DEPLOYMENT == 'Always' || (vars.PAGES_DEPLOYMENT == 'Default' && github.ref_name == github.event.repository.default_branch) }}
11+
if: <%=yamlGenerateDeploymentScript%> == true
1212
runs-on: ubuntu-latest
1313

1414
permissions:

packages/igx-templates/igx-ts/projects/_base/files/__dot__github/workflows/github-pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88

99
jobs:
1010
build-and-deploy:
11-
if: ${{ vars.PAGES_DEPLOYMENT == 'Always' || (vars.PAGES_DEPLOYMENT == 'Default' && github.ref_name == github.event.repository.default_branch) }}
11+
if: <%=yamlGenerateDeploymentScript%> == true
1212
runs-on: ubuntu-latest
1313

1414
permissions:

packages/igx-templates/igx-ts/projects/_base/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,8 @@ $app-palette: palette($primary, $secondary, $surface);
6767
projectTemplate: this.id,
6868
igxPackage: NPM_ANGULAR,
6969
yamlDefaultBranch: "<%=yaml-default-branch%>", // the placeholder will be evaluated by CodeGen
70-
ApplicationTitle: "<%=ApplicationTitle%>" // the placeholder will be evaluated by CodeGen
70+
ApplicationTitle: "<%=ApplicationTitle%>", // the placeholder will be evaluated by CodeGen
71+
yamlGenerateDeploymentScript: "<%=yaml-generate-deployment-script%>" // the placeholder will be evaluated by CodeGen
7172
};
7273

7374
switch (theme) {

packages/igx-templates/igx-ts/projects/_base_with_home/files/__dot__github/workflows/github-pages.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88

99
jobs:
1010
build-and-deploy:
11-
if: ${{ vars.PAGES_DEPLOYMENT == 'Always' || (vars.PAGES_DEPLOYMENT == 'Default' && github.ref_name == github.event.repository.default_branch) }}
11+
if: <%=yamlGenerateDeploymentScript%> == true
1212
runs-on: ubuntu-latest
1313

1414
permissions:

0 commit comments

Comments
 (0)