This commit is contained in:
parent
6618b04a26
commit
9762e793cb
@ -17,23 +17,14 @@ jobs:
|
|||||||
|
|
||||||
# 設定變數
|
# 設定變數
|
||||||
$projectPath = "D:\Code\Project\TCM"
|
$projectPath = "D:\Code\Project\TCM"
|
||||||
$backendPath = "$projectPath\Backend"
|
$backendPath = "D:\Code\Project\TCM\Backend"
|
||||||
$apiPath = "D:\Code\Server\TCM\API"
|
$apiPath = "D:\Code\Server\TCM\API"
|
||||||
|
|
||||||
# 確保主資料夾存在
|
cd D:\Code\Project\TCM
|
||||||
if (-not (Test-Path $projectPath)) {exit 1}
|
if (Test-Path "Backend") { Remove-Item -Recurse -Force "Backend" } # 刪除原資料
|
||||||
|
if (-not (Test-Path "Backend")) {New-Item -Path "Backend" -ItemType Directory -Force} # 建立資料夾
|
||||||
cd $projectPath
|
echo " Cloneing ..."
|
||||||
|
git clone -b develop http://leovip125.ddns.net:8418/TCM/Backend.git
|
||||||
# 刪除原 Backend 資料夾
|
|
||||||
if (Test-Path $backendPath) { Remove-Item -Recurse -Force $backendPath }
|
|
||||||
|
|
||||||
# 確保目標資料夾存在
|
|
||||||
New-Item -Path $backendPath -ItemType Directory -Force | Out-Null
|
|
||||||
|
|
||||||
echo " Cloning repository..."
|
|
||||||
git clone -b develop http://leovip125.ddns.net:8418/TCM/Backend.git $backendPath
|
|
||||||
if ($LASTEXITCODE -ne 0) { exit 1}
|
|
||||||
echo "Clone End"
|
echo "Clone End"
|
||||||
|
|
||||||
# .NET 發布
|
# .NET 發布
|
||||||
|
Loading…
x
Reference in New Issue
Block a user