by alexander white ©
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<profiles> | |
<profile> | |
<id>normal</id> | |
<activation> | |
<activeByDefault>true</activeByDefault> | |
</activation> | |
<properties> | |
<surefireArgLine></surefireArgLine> <!--create blank property for surefire when not running under coverage profile--> | |
<failsafeArgLine></failsafeArgLine> <!--create blank property for failsafe when not running under coverage profile--> | |
</properties> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from click import command, option, Option, UsageError | |
class MutuallyExclusiveOption(Option): | |
def __init__(self, *args, **kwargs): | |
self.mutually_exclusive = set(kwargs.pop('mutually_exclusive', [])) | |
help = kwargs.get('help', '') | |
if self.mutually_exclusive: | |
ex_str = ', '.join(self.mutually_exclusive) | |
kwargs['help'] = help + ( |