Skip to main content

A Python package for interacting with the Gitea API, offering a simple interface to access repositories, users, organizations, issues, and more for automation and data management.

Project description

python-gitea

Python CI pre-commit.ci status Documentation Status codecov PyPI Version Python Versions License: MIT Security: bandit DOI

Note: This project is still in progress. The promised features are not fully ready yet, and APIs are subject to change.

A Python package for interacting with the Gitea API. This package provides a simple and intuitive interface to access Gitea repositories, users, organizations, issues, and more, enabling seamless integration with Gitea instances for automation, data retrieval, and management tasks.

Features

Full API Coverage: Access to repositories, users, organizations, issues, pull requests, and more.

  • Easy Authentication: Support for token-based authentication.
  • Asynchronous Support: Built with async/await for non-blocking operations.
  • Type Hints: Full type annotations for better IDE support and code reliability.
  • Comprehensive Documentation: Detailed guides and API reference.
  • Command-Line Interface: Interact with the Gitea API directly from the terminal for quick, scriptable operations without writing code.

Installation

We recommend using uv to manage virtual environments for installing python-gitea.

If you don't have uv installed, you can install it with pip. See the project pages for more details:

  • Install via pip: pip install --upgrade pip && pip install uv
  • Project pages: uv on PyPI | uv on GitHub
  • Full documentation and usage guide: uv docs

Requirements

  • Python 3.10 or higher
  • Operating System: Linux, macOS, or Windows

Install from PyPI

The recommended way to install python-gitea is from PyPI:

# Create a virtual environment (recommended with uv)
uv venv --python 3.10
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
uv pip install python-gitea

Optional Dependencies

For development or specific features:

# Development dependencies (testing, linting, etc.)
uv pip install python-gitea[dev]

# Documentation dependencies
uv pip install python-gitea[docs]

# All dependencies
uv pip install python-gitea[dev,docs]

Install from Source

For the latest development version:

git clone git@github.com:isaac-cf-wong/python-gitea.git
cd python-gitea
# Create a virtual environment (recommended with uv)
uv venv --python 3.10
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
uv pip install .

Development Installation

To set up for development:

git clone git@github.com:isaac-cf-wong/python-gitea.git
cd python-gitea

# Create a virtual environment (recommended with uv)
uv venv --python 3.10
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
uv pip install ".[dev]"

# Install the commitlint dependencies
npm install

# Install pre-commit hooks
pre-commit install
pre-commit install --hook-type commit-msg

Verify Installation

Check that python-gitea is installed correctly:

gitea-cli --help
python -c "import gitea; print(gitea.__version__)"

License

This project is licensed under the MIT License - see the LICENSE file for details.

Support

For questions, issues, or contributions, please:

Changelog

See Release Notes for version history.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

python_gitea-0.3.0.tar.gz (43.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

python_gitea-0.3.0-py3-none-any.whl (27.6 kB view details)

Uploaded Python 3

File details

Details for the file python_gitea-0.3.0.tar.gz.

File metadata

  • Download URL: python_gitea-0.3.0.tar.gz
  • Upload date:
  • Size: 43.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for python_gitea-0.3.0.tar.gz
Algorithm Hash digest
SHA256 95c4accdba7d443f3ff187b737387cb8103388df9616e87c7d31d5df897d0406
MD5 0628e7a92307f8a33658e708d376e89b
BLAKE2b-256 8a7929bce9b9dc74a675c746c526d8545ff12d375918284214371ea23a906277

See more details on using hashes here.

Provenance

The following attestation bundles were made for python_gitea-0.3.0.tar.gz:

Publisher: create_tag.yml on isaac-cf-wong/python-gitea

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file python_gitea-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: python_gitea-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 27.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for python_gitea-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 595fe448ae8e37e80323c39a5dc4cc33a6a8d68d0d40b7174495727b46ff5345
MD5 c27cf5a739f77be15b32d94ce09609a4
BLAKE2b-256 05f4c9c1b48e1429e1290d5832afa1a7d4e0063e69c0fca96e8e869e8f75bcfd

See more details on using hashes here.

Provenance

The following attestation bundles were made for python_gitea-0.3.0-py3-none-any.whl:

Publisher: create_tag.yml on isaac-cf-wong/python-gitea

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page