Add setup.py with console_script to allow for shell command installation#7
Add setup.py with console_script to allow for shell command installation#7sjossi wants to merge 3 commits intonetspooky:mainfrom
Conversation
|
My apologies, I tested it again today and it didn't work properly. I'll fix it asap |
|
@sjossi you might consider using poetry instead it. You can actually use pyproject with setuptools but I haven't tried to. At some point I settled on poetry over that option. They are nearly interchangeable but I believe poetry offers some things that you won't get just with setuptools but in any case:
if you'd like an example: https://github.com/paigeadelethompson/ruledownloader/blob/master/pyproject.toml that whole project is poetry and shipped on pypi, and you can just simply These are the actual userland commands and their entrypoints that get installed to https://github.com/paigeadelethompson/ruledownloader/blob/master/pyproject.toml#L32 |
|
also @netspooky if you want to deploy this on pypi, you can use this github workflow: https://github.com/paigeadelethompson/ruledownloader/blob/master/.github/workflows/python-pypi.yml If you don't have an account setup, create one, enable 2fa for login and disable 2fa for the deployment part of it, but create an api token just for the project and specify it in the repo secrets (under the settings for the repo.) I'm not a big fan of how PyPI works but at least what they have isn't too difficult to work with from my experience with it. If you're not interested in messing with PyPI but like this idea then I don't particularly mind facilitating this for you, just let me know. Also @sjossi if you like the idea but don't particularly want to mess with it then I will turn this into poetry, if it pleases @netspooky. EDIT: you are in luck, |
Thanks for the release! I expect to use it in a range of projects and I'm lazy, so I took the liberty of writing a simple setup.py to allow for a pip install.
It's quite minimal and I got the information from the source (version and license), please let me know if something is wrong.
I tried not to touch any core code, but I had to add a
__main__and amain()function inscare.pyso I could call it from the console. I hope that's not an issue.