ususdei / qute-keepassxc

Qutebrowser userscript to fetch credentials from KeepassXC password database
MIT License
54 stars 10 forks source link

Make script publishable with poetry #7

Closed bodograumann closed 3 years ago

bodograumann commented 3 years ago

I did not want to have some manually installed dangling dependencies, so I made this script into a python package. For now I can run poetry build and then pip install --user ./dist/qute_keepassxc-0.1.0-py3-none-any.whl. This gives me a qute-keepassxc executable in ~/.local/bin. In it there is an import of qute_keepassxc. That is why I had to change the file name. Dashes in python package names make them hard to import.

My suggestion for you would be to publish this package to pypi. Then if somebody wants to use the script, they can simply run pip install qute-keepassxc and add the keyboard shortcuts, without manually installing any dependencies.

ususdei commented 3 years ago

I totally agree that maintaining some random git clone is not really convenient for most users.

While I appreciate the declarative simplicity of poetry (I have only used setup.py until now), I mainly have two issues with this PR as it is right now:

1) Publishing this script like any other executable doesn't feel right as it is not callable from a shell but requires the qutebrowser environment to run. So ~/.local/bin is not really the right place for it.

2) Renaming the script might break existing setups which use the documented symlinks.

I think, the most convenient way for all users would be if qute-keepassxc was deployed as part of qutebrowser itself.

I should probably ask there first, if there is any chance of getting this repo integrated into qutebrowser. If so, this would be my goto approach.

Otherwise I might fork of a new main-branch or similar to contain the changes required for deploying this on pypi.