Skip to content

manifest: allow an empty --variant to clear it - #7444

Open
locker95 wants to merge 1 commit into
docker:masterfrom
locker95:fix-annotate-clear-variant
Open

locker95 wants to merge 1 commit into
docker:masterfrom
locker95:fix-annotate-clear-variant

Conversation

@locker95

Copy link
Copy Markdown
Contributor

--variant "" didn't clear a variant that was already set, because annotate skipped the field whenever the value was empty.

It now updates the variant when the flag is actually passed, including an empty one. Leaving the flag off still keeps the current value.

Fixes #4352

annotate only wrote the variant when the string was non-empty, so
`--variant ""` left the previous value in place.

Fixes docker#4352

Signed-off-by: Dean Chen <862469039@qq.com>
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docker annotate can't remove variant

2 participants