mirror of
https://github.com/tiennm99/ccs.git
synced 2026-10-11 12:09:03 +00:00
hotfix(ci): preserve literal snippet indentation in ai review comments
This commit is contained in:
1 parent
07b4275543
commit
f6779a503a
4 files changed
+49
-5
No files matched your search
@@ -47,9 +47,15 @@ function cleanText(value) {
|
||||
}
|
||||
|
||||
function cleanMultilineText(value) {
|
||||
return typeof value === 'string'
|
||||
? value.trim().replace(/\r\n/g, '\n').replace(/\r/g, '\n')
|
||||
: '';
|
||||
if (typeof value !== 'string') {
|
||||
return '';
|
||||
}
|
||||
|
||||
return value
|
||||
.replace(/\r\n/g, '\n')
|
||||
.replace(/\r/g, '\n')
|
||||
.replace(/^\n+/u, '')
|
||||
.replace(/\n+$/u, '');
|
||||
}
|
||||
|
||||
function escapeMarkdown(value) {
|
||||
|
||||
@@ -101,7 +101,7 @@ Return a single object with these keys only:
|
||||
- overallRationale
|
||||
|
||||
Each finding may optionally include:
|
||||
- snippets: an array of up to 2 objects with keys label, language, and code
|
||||
- snippets: an array of up to 2 objects with required code plus optional label and language
|
||||
|
||||
If snippets are present:
|
||||
- keep code literal only, without markdown fences
|
||||
|
||||
Reference in new issue
Block a user