Closed peterjc closed 8 years ago
While this works, putting the content in __init__.py
feels a bit dirty; we could easily encounter a circular dependency or load unnecessary dependencies. Additionally, this breaks our existing foundry
release setup =/.
Maybe we can move to a restructuredtext_lint/version.txt
file? That would be easier to set up as a custom step in foundry
(e.g. echo $VERSION
)
Also I concur with only keeping --version
, let's leave -v
alone for now
Does anyone use your code from within Python (via import restructuredtext_lint
)? If so then you really ought to have the version available there too (e.g. in __init__.py
as currently proposed).
I'm not familiar with foundry.
I mean __init__.py
could load up __version__
as well but it seems backwards to have cli.py
loading __init__.py
as that's a circular dependency =/
Given the version definition is innately tied to your release process and the packaging, I'm 100% OK with you taking this PR purely as a suggestion, and doing something a bit different.
I probably will. Sorry for wasting your time/energy. I forgot about the complexities of Python library management x_x
No problem - I'll try to check back and see how you end up solving this as I may learn a trick or two 👍
Pull request to implement #31.
Tested locally via
python3.5 setup.py install
and also confirmedpython3.5 setup.py bdist
seems to work.Also checked:
New behaviour:
NOTE: Might you want to reserve
-v
for a future verbose option?