Skip to content

Latest commit

 

History

History
93 lines (66 loc) · 3.38 KB

CONTRIBUTING.md

File metadata and controls

93 lines (66 loc) · 3.38 KB

Contributing to QGIS Earth Engine Plugin

Thank you for your interest in contributing to the QGIS Earth Engine Plugin! We appreciate your support and contributions.

Setting Up for Local Development

Follow these steps to set up the plugin locally for development:

  1. Clone the repository:

    git clone https://github.com/gee-community/qgis-earthengine-plugin.git
    cd qgis-earthengine-plugin
  2. Install dependencies and set up the QGIS python environment using paver:

    paver setup
  3. Create a symlink of this project into the QGIS plugin directory:

    paver install
  4. Open QGIS and enable the plugin via the plugin manager. Verify that the custom about message is displayed.

Debugging within VSCode

The plugin can be debugged within Visual Studio Code with the help of the debugvs QGIS plugin.

Note

At time of writing, an outstanding PR is required to successfully debug QGIS. This fix can manually be applied by copying the __init__.py file to your local installation of the debugvs plugin.

Example MacOSX:

curl https://raw.githubusercontent.com/lmotta/debug_vs_plugin/f1f28d72eb0221581b51c7dd1e4d0435db991eb8/__init__.py >> ~/Library/Application\ Support/QGIS/QGIS3/profiles/default/python/plugins/debug_vs/__init__.py

Workflow

  1. Within QGIS:
    • Start “Enable Debug for Visual Studio Code” plugin.
  2. Within the qgis-earthengine-plugin codebase opened within VSCode:
    • In Debug tools, launch the Run and Debug for “Python: Remote Attach”
    • In the codebase, add breakpoints where desired.
  3. Within QGIS:
    • Run EarthEngine QGIS plugin to trigger code at desired breakpoints.

Code Contribution Process

  1. Ensure your contribution addresses an existing issue or discussion topic in the repository. If it does not, please open an issue to discuss your idea before starting.

  2. Create a new branch for your changes:

    git checkout -b feature/your-feature-name
  3. Make your changes and ensure they follow the project’s coding standards.

  4. Test your changes locally including reinstalling new dependencies for the QGIS environment with:

    paver setup
  5. Commit your changes with a clear and descriptive message:

    git commit -m "Add a clear description of your changes"
  6. Push your changes to your forked repository:

    git push origin feature/your-feature-name
  7. Open a Pull Request (PR) against the main repository. Ensure your PR description includes the problem it solves, a summary of changes, and any additional notes.

Coding Standards

  • Follow Python’s PEP 8 guidelines for code style.
  • Ensure that your code is well-documented with comments and docstrings.
  • Use descriptive variable and function names.

Testing

  • Test your changes thoroughly before submitting a PR.
  • If possible, add tests to cover your changes and ensure they pass.

Questions or Help?

If you have any questions or need assistance, feel free to reach out by creating an issue in the repository or contacting the original author: [email protected].

Thank you for contributing to the QGIS Earth Engine Plugin!