2022-01-16 19:52:12 +01:00
|
|
|
import bump
|
|
|
|
import typer
|
|
|
|
|
|
|
|
cli = typer.Typer()
|
|
|
|
|
|
|
|
@cli.command()
|
2022-01-16 22:22:19 +01:00
|
|
|
def default(message = typer.Argument(None, help="The message to be bumped")):
|
2022-01-16 19:52:12 +01:00
|
|
|
bp = bump.Bump()
|
|
|
|
if message is None:
|
|
|
|
bp.show_secret()
|
|
|
|
else:
|
|
|
|
bp.push(message)
|
|
|
|
|
|
|
|
@cli.command()
|
|
|
|
def push():
|
|
|
|
bp = bump.Bump()
|
|
|
|
bp.version()
|
|
|
|
|
2022-01-16 22:22:19 +01:00
|
|
|
def main():
|
|
|
|
typer.run(default)
|
|
|
|
|
2022-01-16 19:52:12 +01:00
|
|
|
if __name__ == "__main__":
|
2022-01-16 22:22:19 +01:00
|
|
|
main()
|