Skip to content

configmgr extract: no new line for the last array item#525

Open
Martin-Zeithaml wants to merge 4 commits intov3.x/stagingfrom
v3.x/feature/extract
Open

configmgr extract: no new line for the last array item#525
Martin-Zeithaml wants to merge 4 commits intov3.x/stagingfrom
v3.x/feature/extract

Conversation

@Martin-Zeithaml
Copy link
Copy Markdown
Contributor

configmgr extract feature is printing new line character for each key found. But for the array, it prints new line char twice, which is might be confusing for arrays with empty strings.

test:
  array1:
    - 'apple'
    - 'banana'
    - 'kiwi'
    - ''

Without fix

There are 2 empty lines at the end, which might be considered as 2 empty items:

apple
banana
kiwi


With fix

apple
banana
kiwi

Empty item, not last and with fix

test:
  array1:
    - 'apple'
    - 'banana'
    - 'kiwi'
    - ''
    - 'plum'
apple
banana
kiwi

plum

Signed-off-by: Martin Zeithaml <Martin.Zeithaml@broadcom.com>
Copy link
Copy Markdown
Contributor

@JoeNemo JoeNemo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved.

@github-actions github-actions Bot added the stale-reopen-if-needed An issue closed due to inactivity. No indication of completion or validity. label Mar 9, 2026
@sonarqubecloud
Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
B Maintainability Rating on New Code (required ≥ A)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

@github-actions github-actions Bot removed the stale-reopen-if-needed An issue closed due to inactivity. No indication of completion or validity. label Mar 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

2 participants