Development Environment
This guide explains how to prepare a local development environment for GitHub Repository Sync.
A consistent development environment helps ensure that contributors can build, test and debug the application reliably across different operating systems.
Prerequisites
Before working on the project, ensure the following software is installed.
Python
GitHub Repository Sync requires a supported version of Python.
Verify your installation:
or
Refer to the project's installation documentation for the currently supported Python versions.
Git
Git is required for cloning the repository and contributing changes.
Verify your installation:
pip
The Python package installer is required for installing project dependencies.
Verify your installation:
Virtual Environment Support
A virtual environment is strongly recommended to isolate project dependencies.
Verify that the venv module is available:
Clone the Repository
Clone the repository using Git.
Change into the project directory.
Create a Virtual Environment
Create a virtual environment inside the project.
Activate the environment.
Linux
macOS
Windows (PowerShell)
Once activated, the shell prompt should indicate that the virtual environment is active.
Install Development Dependencies
Install the project in editable mode together with its development dependencies.
Editable mode allows source code changes to take effect immediately without reinstalling the package.
Verify the Installation
Confirm that the application starts successfully.
or
The exact invocation may vary depending on your installation method.
Recommended Development Tools
The following tools are recommended during development.
| Tool | Purpose |
|---|---|
| Git | Source control. |
| Python | Application runtime. |
| pip | Package management. |
| virtualenv / venv | Isolated development environment. |
| pytest | Test execution. |
| Ruff | Linting and formatting. |
| MkDocs | Documentation preview. |
Depending on your workflow, additional IDE or editor extensions may also be useful.
Documentation Preview
The project documentation is built using MkDocs.
Start the local documentation server.
The documentation can then be viewed in your web browser.
The server automatically rebuilds the documentation whenever files are modified.
Running the Test Suite
Execute the complete test suite.
Run a specific test file.
Run a specific test.
Keeping Dependencies Up to Date
Development dependencies should be updated periodically.
Always run the test suite after updating dependencies.
Development Workflow
A typical development workflow is:
- Clone the repository.
- Create a virtual environment.
- Install development dependencies.
- Create a feature branch.
- Implement the required changes.
- Run the test suite.
- Update the documentation where necessary.
- Commit the changes.
- Submit a pull request.
Following a consistent workflow helps maintain the quality of the project.
Next Steps
Continue to Project Structure for an overview of the repository layout and the purpose of each directory.