✨ feat(templates): add gitea ci example
This commit is contained in:
@@ -80,6 +80,14 @@ copy /y "%SRC%\\.agents\\index.md" "%DEST_PREFIX%\\.agents\\index.md" >nul
|
||||
|
||||
if not exist "%DEST_PREFIX%\\templates" mkdir "%DEST_PREFIX%\\templates"
|
||||
|
||||
if exist "%SRC%\\templates\\ci" (
|
||||
xcopy "%SRC%\\templates\\ci\\*" "%DEST_PREFIX%\\templates\\ci\\" /e /i /y >nul
|
||||
if errorlevel 1 (
|
||||
echo ERROR: failed to copy templates\\ci
|
||||
exit /b 1
|
||||
)
|
||||
)
|
||||
|
||||
set "LANGS_CSV="
|
||||
for %%L in (%LANGS%) do (
|
||||
echo %%~L| findstr /r "[\\/]" >nul && (
|
||||
|
||||
@@ -81,6 +81,11 @@ Copy-Item (Join-Path $Src ".agents/index.md") (Join-Path $AgentsDir "index.md")
|
||||
$TemplatesDir = Join-Path $DestPrefix "templates"
|
||||
New-Item -ItemType Directory -Path $TemplatesDir -Force | Out-Null
|
||||
|
||||
$ciTplSrc = Join-Path (Join-Path $Src "templates") "ci"
|
||||
if (Test-Path $ciTplSrc) {
|
||||
Copy-Item $ciTplSrc $TemplatesDir -Recurse -Force
|
||||
}
|
||||
|
||||
foreach ($lang in $Langs) {
|
||||
$docsSrc = Join-Path (Join-Path $Src "docs") $lang
|
||||
if (-not (Test-Path $docsSrc)) { throw "Docs not found for lang=$lang ($docsSrc)" }
|
||||
|
||||
@@ -81,6 +81,9 @@ mkdir -p "$DEST_PREFIX/.agents"
|
||||
cp "$SRC/.agents/index.md" "$DEST_PREFIX/.agents/index.md"
|
||||
|
||||
mkdir -p "$DEST_PREFIX/templates"
|
||||
if [ -d "$SRC/templates/ci" ]; then
|
||||
cp -R "$SRC/templates/ci" "$DEST_PREFIX/templates/"
|
||||
fi
|
||||
|
||||
old_ifs="${IFS}"
|
||||
IFS=', '
|
||||
|
||||
Reference in New Issue
Block a user