|
| 1 | +Param([string] $rootPath) |
1 | 2 | $scriptPath = Split-Path $script:MyInvocation.MyCommand.Path |
2 | | - |
| 3 | + |
3 | 4 | Write-Host "Current script directory is $scriptPath" -ForegroundColor Yellow |
4 | 5 |
|
| 6 | +if ([string]::IsNullOrEmpty($rootPath)) { |
| 7 | + $rootPath = "$scriptPath\.." |
| 8 | +} |
| 9 | +Write-Host "Root path used is $rootPath" -ForegroundColor Yellow |
| 10 | + |
5 | 11 | # *** WebMVC paths *** |
6 | | -$webMVCPath = $scriptPath + "\src\Web\WebMVC" |
| 12 | +$webMVCPath = $rootPath + "\src\Web\WebMVC" |
7 | 13 | $webMVCPathToProject = $webMVCPath + "\WebMVC.csproj" |
8 | 14 | Write-Host "webMVCPathToProject is $webMVCPathToProject" -ForegroundColor Yellow |
9 | 15 | $webMVCPathToPub = $webMVCPath + "\obj\Docker\publish" |
10 | 16 | Write-Host "webMVCPathToPub is $webMVCPathToPub" -ForegroundColor Yellow |
11 | 17 |
|
12 | 18 |
|
13 | 19 | # *** WebSPA paths *** |
14 | | -$webSPAPath = $scriptPath + "\src\Web\WebSPA" |
| 20 | +$webSPAPath = $rootPath + "\src\Web\WebSPA" |
15 | 21 | $webSPAPathToProject = $webSPAPath + "\WebSPA.csproj" |
16 | 22 | Write-Host "webSPAPathToProject is $webSPAPathToProject" -ForegroundColor Yellow |
17 | 23 | $webSPAPathToPub = $webSPAPath + "\obj\Docker\publish" |
18 | 24 | Write-Host "webSPAPathToPub is $webSPAPathToPub" -ForegroundColor Yellow |
19 | 25 |
|
20 | 26 |
|
21 | 27 | # *** IdentitySvc paths *** |
22 | | -$identitySvcPath = $scriptPath + "\src\Services\Identity\Identity.API" |
| 28 | +$identitySvcPath = $rootPath + "\src\Services\Identity\Identity.API" |
23 | 29 | $identitySvcToProject = $identitySvcPath + "\Identity.API.csproj" |
24 | 30 | Write-Host "identitySvcToProject is $identitySvcToProject" -ForegroundColor Yellow |
25 | 31 | $identitySvcPathToPub = $identitySvcPath + "\obj\Docker\publish" |
26 | 32 | Write-Host "identitySvcPathToPub is $identitySvcPathToPub" -ForegroundColor Yellow |
27 | 33 |
|
28 | 34 |
|
29 | 35 | # *** Catalog paths *** |
30 | | -$catalogPath = $scriptPath + "\src\Services\Catalog\Catalog.API" |
| 36 | +$catalogPath = $rootPath + "\src\Services\Catalog\Catalog.API" |
31 | 37 | $catalogPathToProject = $catalogPath + "\Catalog.API.csproj" |
32 | 38 | Write-Host "catalogPathToProject is $catalogPathToProject" -ForegroundColor Yellow |
33 | 39 | $catalogPathToPub = $catalogPath + "\obj\Docker\publish" |
34 | 40 | Write-Host "catalogPathToPub is $catalogPathToPub" -ForegroundColor Yellow |
35 | 41 |
|
36 | 42 |
|
37 | 43 | # *** Ordering paths *** |
38 | | -$orderingPath = $scriptPath + "\src\Services\Ordering\Ordering.API" |
| 44 | +$orderingPath = $rootPath + "\src\Services\Ordering\Ordering.API" |
39 | 45 | $orderingPathToProject = $orderingPath + "\Ordering.API.csproj" |
40 | 46 | Write-Host "orderingPathToProject is $orderingPathToProject" -ForegroundColor Yellow |
41 | 47 | $orderingPathToPub = $orderingPath + "\obj\Docker\publish" |
42 | 48 | Write-Host "orderingPathToPub is $orderingPathToPub" -ForegroundColor Yellow |
43 | 49 |
|
44 | 50 | # *** Basket paths *** |
45 | | -$basketPath = $scriptPath + "\src\Services\Basket\Basket.API" |
| 51 | +$basketPath = $rootPath + "\src\Services\Basket\Basket.API" |
46 | 52 | $basketPathToProject = $basketPath + "\Basket.API.csproj" |
47 | 53 | Write-Host "basketPathToProject is $basketPathToProject" -ForegroundColor Yellow |
48 | 54 | $basketPathToPub = $basketPath + "\obj\Docker\publish" |
|
0 commit comments