Skip to content

Commit 1be307e

Browse files
azure-powershell-botazurepowershell
andauthored
Sync tools folder from main branch to generation branch (#24078)
Co-authored-by: azurepowershell <[email protected]>
1 parent a927ed3 commit 1be307e

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

tools/DevTools/CommonRepo.psm1

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,16 +36,28 @@ function Connect-CommonRepo {
3636
if ($LASTEXITCODE -ne 0) {
3737
throw "Failed to add $csproj to Accounts.sln"
3838
}
39+
<#
40+
known common project references:
41+
Authentication.csproj -> Authentication.Abstractions, ResourceManager
42+
Accounts.csproj -> Authentication.Abstractions, ResourceManager, Common
43+
Accounts.Test.csproj -> Authentication.Abstractions, ResourceManager, Common
44+
TestFx.csproj -> Graph.Rbac.csproj
45+
AssemblyLoading.csproj -> Common
46+
#>
47+
# add all common projects to Authentication.csproj because it will be referenced by most Az projects
3948
dotnet add ./Authentication/Authentication.csproj reference $csproj
4049
if ($LASTEXITCODE -ne 0) {
4150
throw "Failed to add $csproj to Authentication.csproj"
4251
}
4352
}
4453

54+
# AssemblyLoading.csproj references Common.csproj and does not reference Autehtication.csproj
4555
dotnet add ./AssemblyLoading/AssemblyLoading.csproj reference "$CommonRepoPath/src/Common/Common.csproj"
4656
if ($LASTEXITCODE -ne 0) {
4757
throw "Failed to add Common.csproj to AssemblyLoading.csproj"
4858
}
59+
60+
# add common project references below for csproj which does not reference Authentication.csproj
4961
}
5062
finally {
5163
Pop-Location
@@ -81,7 +93,6 @@ function Connect-CommonRepo {
8193
function Disconnect-CommonRepo {
8294
Write-Host "Please run the following commands to undo Connect-CommonRepo. Double check those files do not have wanted changes.
8395
git checkout -- ./src/Accounts/Accounts.sln
84-
git checkout -- ./src/Accounts/Accounts/Accounts.csproj
8596
git checkout -- ./src/Accounts/AssemblyLoading/AssemblyLoading.csproj
8697
git checkout -- ./src/Accounts/Authentication/Authentication.csproj
8798
git checkout -- ./tools/Common.Netcore.Dependencies.targets

0 commit comments

Comments
 (0)