File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -94,8 +94,7 @@ if ($ExcludeComponents) {
94
94
$Components = $Components | Where-Object { $_ -notin $ExcludeComponents }
95
95
}
96
96
97
- # Certain Components are required to build the gallery app.
98
- # Add them if not already included.
97
+ # Certain ProjectReferences should always be generated (are required to build gallery) if csproj is available.
99
98
if ($Components -notcontains ' SettingsControls' ) {
100
99
$Components += ' SettingsControls'
101
100
}
Original file line number Diff line number Diff line change @@ -28,8 +28,14 @@ foreach ($componentName in $Components) {
28
28
continue ;
29
29
}
30
30
31
+ # Don't generate project reference if component isn't available
32
+ if (! (Test-Path " $PSScriptRoot /../../components/$componentName /" )) {
33
+ continue ;
34
+ }
35
+
31
36
# Find all components source csproj (when wildcard), or find specific component csproj by name.
32
37
foreach ($componentPath in Get-Item " $PSScriptRoot /../../components/$componentName /" ) {
38
+ $componentName = $componentPath.BaseName ;
33
39
Write-Output " Generating project references for component $componentName at $componentPath " ;
34
40
35
41
# Find source and sample csproj files
You can’t perform that action at this time.
0 commit comments