This particular setup doesn't behave the way I want: https://go.dev/play/p/vYCFMxlM9Lk
(gist in case the playground link ever expires https://gist.github.com/dgunay/3755d6956bc2c35ce11b26961c8fe97b)
I want to be able to reuse the behavior "either --name=STRING or --pick are required", by embedding the struct into other commands. It works, until I add the kong:"predictor=session-name" tag, then the xor requirement no longer works.
I am able to work around it by changing all the tags to go under a kong: tag. Changing the predictor tag to be bare does not work (probably due to some implementation detail of https://github.com/WillAbides/kongplete.)
Anyway, this contradicts the readme:
|
Both can coexist with standard Tag parsing. |
This particular setup doesn't behave the way I want: https://go.dev/play/p/vYCFMxlM9Lk
(gist in case the playground link ever expires https://gist.github.com/dgunay/3755d6956bc2c35ce11b26961c8fe97b)
I want to be able to reuse the behavior "either
--name=STRINGor--pickare required", by embedding the struct into other commands. It works, until I add thekong:"predictor=session-name"tag, then the xor requirement no longer works.I am able to work around it by changing all the tags to go under a
kong:tag. Changing the predictor tag to be bare does not work (probably due to some implementation detail of https://github.com/WillAbides/kongplete.)Anyway, this contradicts the readme:
kong/README.md
Line 566 in ecee830