mirror of
https://github.com/Nikolay-Shirokov/cc-1c-skills.git
synced 2026-08-13 23:13:22 +03:00
feat(validate): auto-resolve directory paths, fix SKILL.md placeholders
Scripts now accept directory paths (e.g. Forms/ИмяФормы) and auto-resolve to the target XML file. Silent fallbacks handle missing Ext/ level and descriptor-to-file resolution. SKILL.md: concrete placeholders, unified quotes, auto-resolve notes, role-validate MaxErrors in params. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
422e397381
commit
b2a2534b5a
@@ -14,6 +14,18 @@ $ErrorActionPreference = "Stop"
|
||||
if (-not [System.IO.Path]::IsPathRooted($CIPath)) {
|
||||
$CIPath = Join-Path (Get-Location).Path $CIPath
|
||||
}
|
||||
# A: Directory → Ext/CommandInterface.xml
|
||||
if (Test-Path $CIPath -PathType Container) {
|
||||
$CIPath = Join-Path (Join-Path $CIPath "Ext") "CommandInterface.xml"
|
||||
}
|
||||
# B1: Missing Ext/ (e.g. Subsystems/X/CommandInterface.xml → Subsystems/X/Ext/CommandInterface.xml)
|
||||
if (-not (Test-Path $CIPath)) {
|
||||
$fn = [System.IO.Path]::GetFileName($CIPath)
|
||||
if ($fn -eq "CommandInterface.xml") {
|
||||
$c = Join-Path (Join-Path (Split-Path $CIPath) "Ext") $fn
|
||||
if (Test-Path $c) { $CIPath = $c }
|
||||
}
|
||||
}
|
||||
if (-not (Test-Path $CIPath)) {
|
||||
Write-Host "[ERROR] File not found: $CIPath"
|
||||
exit 1
|
||||
|
||||
Reference in New Issue
Block a user