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