Skip to content

feat: support --target for template compatibility markers#86

Merged
tgonzalezorlandoarm merged 1 commit intomainfrom
compatibility-by-target
Mar 11, 2026
Merged

feat: support --target for template compatibility markers#86
tgonzalezorlandoarm merged 1 commit intomainfrom
compatibility-by-target

Conversation

@tgonzalezorlandoarm
Copy link
Copy Markdown
Contributor

Changes

Use --target on topo templates to generate a target description on the fly and annotate compatibility markers without requiring --target-description.
Keep --target-description behavior unchanged, make the flags mutually exclusive.

@tgonzalezorlandoarm tgonzalezorlandoarm requested a review from a team as a code owner March 9, 2026 17:28
@tgonzalezorlandoarm tgonzalezorlandoarm self-assigned this Mar 9, 2026
@tgonzalezorlandoarm tgonzalezorlandoarm marked this pull request as draft March 9, 2026 17:29
@tgonzalezorlandoarm tgonzalezorlandoarm force-pushed the compatibility-by-target branch 3 times, most recently from bc44728 to 7488ede Compare March 10, 2026 13:15
@tgonzalezorlandoarm tgonzalezorlandoarm marked this pull request as ready for review March 10, 2026 13:21
Use --target on topo templates to generate a target description
on the fly and annotate compatibility markers without requiring
--target-description.
Keep --target-description behavior unchanged, make the flags
mutually exclusive.

Signed-off-by: Tomás González <[email protected]>
Copy link
Copy Markdown
Contributor

@muchzill4 muchzill4 left a comment

Choose a reason for hiding this comment

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

LGTM.


Perhaps for another PR:
I do wonder if we should have a:

retrieveTargetDescription(cmd *cobra.Command) (*target.HardwareDescription, error)
addTargetDescriptionFlag(cmd *cobra.Command) // adds `--target-description`
addTargetDescriptionFlags(cmd *cobra.Command) // or `addTargetFlags()` - this would add both `--target` and `--target-description`

It'd essentially do the flow you're doing here, but be reusable for future commands.

@tgonzalezorlandoarm tgonzalezorlandoarm merged commit 5463065 into main Mar 11, 2026
3 checks passed
@tgonzalezorlandoarm tgonzalezorlandoarm deleted the compatibility-by-target branch March 11, 2026 14:41
@tgonzalezorlandoarm
Copy link
Copy Markdown
Contributor Author

LGTM.

Perhaps for another PR: I do wonder if we should have a:

retrieveTargetDescription(cmd *cobra.Command) (*target.HardwareDescription, error)
addTargetDescriptionFlag(cmd *cobra.Command) // adds `--target-description`
addTargetDescriptionFlags(cmd *cobra.Command) // or `addTargetFlags()` - this would add both `--target` and `--target-description`

It'd essentially do the flow you're doing here, but be reusable for future commands.

I've created a draft PR for this so that I don't forget: #92

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.

2 participants