ci(docker): 将脚本中的中文注释和输出信息改为英文
Some checks failed
Build Windows / ACT Windows Checkout Verification (push) Successful in 7h0m13s
Build Windows / 编译 libcore (Windows) (20.15.1) (push) Failing after 17s
Build Windows / build (push) Has been skipped

This commit is contained in:
shanshanzhong 2025-11-07 04:53:22 -08:00
parent 62d3157665
commit eb4db67fa1

View File

@ -239,43 +239,43 @@ jobs:
- name: 🔍 Verify jq Installation (ACT)
shell: powershell
run: |
# 检查 jq 是否可用
# Check if jq is available
$jqFound = $false
try {
$version = jq --version 2>&1
if ($version -match 'jq-[\d\.]+') {
Write-Host "✅ jq 已安装: $version"
Write-Host "jq is already installed: $version"
$jqFound = $true
}
} catch {
Write-Host "❌ jq 未安装或不在 PATH 中"
Write-Host "jq not installed or not in PATH"
}
if (-not $jqFound) {
Write-Host "⚠️ 准备安装 jq..."
# 检查 Chocolatey 是否可用
Write-Host "Preparing to install jq..."
# Check if Chocolatey is available
$chocoFound = $false
try {
choco --version 2>&1 | Out-Null
$chocoFound = $true
} catch {}
if (-not $chocoFound) {
Write-Host "📦 安装 Chocolatey..."
Write-Host "Installing Chocolatey..."
Set-ExecutionPolicy Bypass -Scope Process -Force
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072
iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
# 刷新 PATH
$env:PATH = [System.Environment]::GetEnvironmentVariable("PATH", "Machine") + ";" + [System.Environment]::GetEnvironmentVariable("PATH", "User")
Write-Host "✅ Chocolatey 安装完成"
iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
# Refresh PATH
$env:PATH = [System.Environment]::GetEnvironmentVariable('PATH', 'Machine') + ';' + [System.Environment]::GetEnvironmentVariable('PATH', 'User')
Write-Host "Chocolatey installed successfully"
}
Write-Host "📦 使用 Chocolatey 安装 jq..."
Write-Host "Installing jq using Chocolatey..."
choco install jq -y
if ($LASTEXITCODE -eq 0) {
Write-Host "✅ jq 安装成功"
# 再次验证
Write-Host "jq installed successfully"
# Verify again
$version = jq --version 2>&1
Write-Host "✅ jq 版本: $version"
Write-Host "jq version: $version"
} else {
Write-Host "❌ jq 安装失败,退出码: $LASTEXITCODE"
Write-Host "jq installation failed, exit code: $LASTEXITCODE"
exit 1
}
}