fix: rename awk variable in_body to inbody to avoid smoke test false positive
The agent-smoke.sh function resolution checker matches lowercase_underscore identifiers as potential bash function calls. The awk variable `in_body` inside sprint-filer.sh's heredoc triggered a false [undef] failure. Also fixes SC2155 (declare and assign separately) in the same file. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
04ff8a6e85
commit
2c9b8e386f
1 changed files with 8 additions and 7 deletions
|
|
@ -129,7 +129,7 @@ parse_subissue_entries() {
|
||||||
BEGIN {
|
BEGIN {
|
||||||
printf "["
|
printf "["
|
||||||
first = 1
|
first = 1
|
||||||
in_body = 0
|
inbody = 0
|
||||||
id = ""; title = ""; labels = ""; depends = ""; body = ""
|
id = ""; title = ""; labels = ""; depends = ""; body = ""
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -154,7 +154,7 @@ parse_subissue_entries() {
|
||||||
printf "{\"id\":\"%s\",\"title\":\"%s\",\"labels\":%s,\"depends_on\":%s,\"body\":\"%s\"}", id, title, labels, depends, body
|
printf "{\"id\":\"%s\",\"title\":\"%s\",\"labels\":%s,\"depends_on\":%s,\"body\":\"%s\"}", id, title, labels, depends, body
|
||||||
|
|
||||||
id = ""; title = ""; labels = "[]"; depends = "[]"; body = ""
|
id = ""; title = ""; labels = "[]"; depends = "[]"; body = ""
|
||||||
in_body = 0
|
inbody = 0
|
||||||
}
|
}
|
||||||
|
|
||||||
/^- id:/ {
|
/^- id:/ {
|
||||||
|
|
@ -213,19 +213,19 @@ parse_subissue_entries() {
|
||||||
}
|
}
|
||||||
|
|
||||||
/^ body: *\|/ {
|
/^ body: *\|/ {
|
||||||
in_body = 1
|
inbody = 1
|
||||||
body = ""
|
body = ""
|
||||||
next
|
next
|
||||||
}
|
}
|
||||||
|
|
||||||
in_body && /^ / {
|
inbody && /^ / {
|
||||||
sub(/^ /, "")
|
sub(/^ /, "")
|
||||||
body = body $0 "\n"
|
body = body $0 "\n"
|
||||||
next
|
next
|
||||||
}
|
}
|
||||||
|
|
||||||
in_body && !/^ / && !/^$/ {
|
inbody && !/^ / && !/^$/ {
|
||||||
in_body = 0
|
inbody = 0
|
||||||
# This line starts a new field or entry — re-process it
|
# This line starts a new field or entry — re-process it
|
||||||
# (awk does not support re-scanning, so handle common cases)
|
# (awk does not support re-scanning, so handle common cases)
|
||||||
if ($0 ~ /^- id:/) {
|
if ($0 ~ /^- id:/) {
|
||||||
|
|
@ -485,7 +485,8 @@ check_and_close_completed_visions() {
|
||||||
# All sub-issues closed — close the vision issue
|
# All sub-issues closed — close the vision issue
|
||||||
filer_log "All ${sub_count} sub-issues for vision #${vid} are closed — closing vision"
|
filer_log "All ${sub_count} sub-issues for vision #${vid} are closed — closing vision"
|
||||||
|
|
||||||
local comment_body="## Vision Issue Completed
|
local comment_body
|
||||||
|
comment_body="## Vision Issue Completed
|
||||||
|
|
||||||
All sub-issues have been implemented and merged. This vision issue is now closed.
|
All sub-issues have been implemented and merged. This vision issue is now closed.
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue