First off, thank you for considering contributing! This project is a unique blend of philosophy and code, and your help is welcome in making it better.
To get the project set up for local development, please follow these steps:
-
Fork and Clone:
- Fork the repository on GitHub.
- Clone your fork to your local machine:
git clone https://github.com/YOUR_USERNAME/Python-Code-Harmonizer.git cd Python-Code-Harmonizer
-
Set Up a Virtual Environment:
- It is highly recommended to use a virtual environment to keep dependencies isolated.
python -m venv .venv source .venv/bin/activate
- It is highly recommended to use a virtual environment to keep dependencies isolated.
-
Install Dependencies:
- The project and all its development dependencies can be installed with a single command. The
-eflag installs the project in "editable" mode, which is essential for development.pip install -r requirements.txt pip install -e .
- The project and all its development dependencies can be installed with a single command. The
Once installed, you can run the harmonizer on any Python file using the harmonizer command-line script:
harmonizer examples/test_code.pyThis project uses pytest for testing. To run the full suite:
pytestWe use black for code formatting and flake8 for linting to ensure a consistent and high-quality codebase.
Before you commit your changes, please run black to automatically format your code:
black src/ tests/You can check for any style issues or potential errors with flake8:
flake8 src/ tests/Our Continuous Integration (CI) pipeline will automatically check for formatting and linting issues, so it's a good idea to run these tools locally before pushing your changes.
- Create a new branch for your feature or bug fix.
- Make your changes, and be sure to add tests if you are adding new functionality.
- Ensure your code is formatted with
blackand passes theflake8checks. - Make sure the full test suite passes with
pytest. - Push your branch to your fork and open a pull request.
Thank you for your contributions!