laser.core.cli
laser.core.cli
Module that contains the command line app.
Why does this file exist, and why not put this in main?
You might be tempted to import things from main later, but that will cause problems: the code will get executed twice:
- When you run
python -midmlaserpython will execute__main__.pyas a script. That means there will not be anyidmlaser.__main__insys.modules. - When you import main it will get executed again (as a module) because
there"s no
idmlaser.__main__insys.modules.
Also see (1) from https://click.palletsprojects.com/en/stable/setuptools/