Thank you for wanting to help improve this project!
-
Fork the repository, then clone your fork:
git clone https://github.com/YourUsername/TranslateJavaProperties.git cd TranslateJavaProperties -
(Optional) Create and activate a virtual environment:
python3 -m venv venv source venv/bin/activate # or for Windows: # python -m venv venv # venv\Scripts\activate
-
Install dependencies:
pip install -r requirements.txt
- All PRs should be made against the
mainbranch. - Include a concise description of the changes.
- Ensure that all tests pass locally (run
pytest -v). - Maintain a consistent coding style; run
black .(or your preferred formatter) before committing if you’ve configured one.
This project uses pip-tools to manage Python dependencies, ensuring reproducible builds.
requirements.in: This file contains the primary, top-level dependencies for the application (e.g.,openai,pyyaml).requirements-dev.in: This file contains dependencies used only for development and testing (e.g.,pytest).requirements.txtandrequirements-dev.txt: These are the locked dependency files generated bypip-compile. They contain the exact versions of all top-level and transitive dependencies. Do not edit these files manually.
When you need to add or update a Python dependency, please edit the appropriate .in file:
requirements.infor production dependencies.requirements-dev.infor development and testing dependencies.
After editing, follow these steps:
- Ensure you have
pip-toolsinstalled in your environment (pip install pip-tools). - Navigate to the project's root directory.
- Re-compile the locked requirement files by running the following commands from the project root:
# (Optionally add --generate-hashes for stronger integrity) pip-compile requirements.in --generate-hashes pip-compile requirements-dev.in --generate-hashes - Commit the changes to both the
.infile and the generated.txtfile to your pull request.
Use pip-tools' pip-sync to exactly match the lockfiles:
pip-sync requirements.txt requirements-dev.txtThis project uses black for code formatting and ruff for linting. Please ensure your contributions are formatted correctly before submitting a pull request.
You can run the formatter and linter from the project root:
black .
ruff . --fixThis will automatically format your code and fix any simple linting issues.
Be respectful and constructive in your interactions. We welcome all suggestions!
If you have any questions, feel free to open an issue or reach out to the maintainers.