Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Packaging with rye, CLI for latin2shaw #72

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

intarga
Copy link

@intarga intarga commented Jun 1, 2024

This PR provides dependency management and packaging infrastructure using rye, along with a command line interface for latin2shaw, with the goal of making the script easier and more pleasant to use:

  • With the rye package set up, we can publish this to PyPI with rye build && rye publish, which would let users install the script with pip install readlex instead of having to clone the repo and figure out the dependencies.
  • After installing with, the CLI allows users to use it directly, and it can be used as a library to build more advanced/specialised tools (I set this up so I can build an ePub converter on top of it).
  • Developers who want to tinker with the script can use rye sync to install the dependencies (including the model) automatically, and keep them sandboxed so they don't interfere with other python projects.

Let me know if you would like any of this to be done differently, I'm happy to change it. Alternatively if it turns out this is not a wanted feature, I'm also happy to maintain it as a fork.

Some warnings though:

  • I haven't actually published the package, since I figure that should be left for the project owner. As such, I couldn't test the examples I put in the README, so if/when we publish this, it would be good to sanity check those examples.
  • To make the script work outside the project directory, I had to change the loading of the json files to be file-relative, instead of working-directory-relative. Unfortunately I think this might break your deployment at readlex.pythonanywhere.com 🙁. I would have fixed this myself, but there doesn't seem to be any deployment config in the repo.

@Shavian-info
Copy link
Owner

Thank you. This looks really exciting. I will need a little time, maybe a week, to get up to speed on this. I hope that's okay. But on a first review it looks like this will do a lot that I've thought would be good to do, but which are a little beyond my current abilities.

@intarga
Copy link
Author

intarga commented Jun 2, 2024

No rush! And please do reach out if you have any questions

@intarga
Copy link
Author

intarga commented Jun 13, 2024

@Shavian-info How's it going?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants