feat(M09-D1): 完成商品目录与库存流水底座

This commit is contained in:
Codex
2026-08-11 03:51:18 +08:00
parent 2de796143f
commit 93af128002
37 changed files with 14683 additions and 58 deletions
+9 -5
View File
@@ -3,7 +3,7 @@ $ErrorActionPreference = "Stop"
$readmePath = "README.md"
$configPath = "docs/configuration.md"
$baselinePath = "docs/current-baseline.md"
$expectedSpec = "V5.6.md"
$expectedSpec = "V5.7.md"
$expectedOrigin = "ssh://git@git.txyundm.cn:2222/panda/qipai.git"
foreach ($path in @($readmePath, $configPath, $baselinePath, $expectedSpec)) {
@@ -23,9 +23,11 @@ $config = Get-Content -Raw -Encoding UTF8 $configPath
$spec = Get-Content -Raw -Encoding UTF8 $expectedSpec
$baseline = Get-Content -Raw -Encoding UTF8 $baselinePath
$recentEngineeringLabel = [regex]::Unescape("\u6700\u8fd1\u5de5\u7a0b\u63d0\u4ea4")
$recentEngineeringCommitLabel = [regex]::Unescape("\u6700\u8fd1\u5de5\u7a0b\u63d0\u4ea4")
$recentEngineeringResultLabel = [regex]::Unescape("\u6700\u8fd1\u5de5\u7a0b\u7ed3\u679c")
$nextEngineeringLabel = [regex]::Unescape("\u4e0b\u4e00\u5de5\u7a0b\u76ee\u6807")
$pendingWord = [regex]::Unescape("\u5f85")
$currentEngineeringPhrase = [regex]::Unescape("\u968f\u672c\u6b21\u4e2d\u6587\u5de5\u7a0b\u63d0\u4ea4\u56fa\u5316")
$requiredSharedValues = @(
$expectedSpec,
@@ -59,7 +61,9 @@ foreach ($value in @($expectedSpec, $expectedOrigin, "admin123", "root123", "101
}
$readmeLines = Get-Content -Encoding UTF8 $readmePath
$recentLine = $readmeLines | Where-Object { $_.Contains($recentEngineeringLabel) } | Select-Object -First 1
$recentLine = $readmeLines | Where-Object {
$_.Contains($recentEngineeringCommitLabel) -or $_.Contains($recentEngineeringResultLabel)
} | Select-Object -Last 1
$nextLine = $readmeLines | Where-Object { $_.Contains($nextEngineeringLabel) } | Select-Object -First 1
if (-not $recentLine) {
throw "README missing recent engineering commit line"
@@ -87,8 +91,8 @@ if (-not $latestEngineeringCommit) {
throw "Could not find a recent engineering commit"
}
if ($readme -notmatch [regex]::Escape($latestEngineeringCommit)) {
throw "README recent engineering commit must reference latest engineering commit $latestEngineeringCommit"
if ($readme -notmatch [regex]::Escape($latestEngineeringCommit) -and -not $readme.Contains($currentEngineeringPhrase)) {
throw "README recent engineering result must reference $latestEngineeringCommit or identify the current staged engineering commit"
}
if ($baseline -notmatch '(?m)^>\s*audited_commit:\s*`?[0-9a-f]{7,40}`?') {