Skip to main content

An AI tool to push files to GitHub repositories

Project description

๐Ÿš€ GHPush

AI-Powered GitHub Pull Request Creation Tool

PyPI version PyPI downloads License: MIT Python 3.11+


๐ŸŒŸ Overview

GHPush is an intelligent command-line tool that revolutionizes your GitHub workflow by automating pull request creation. It operates in two modes:

  • ๐Ÿค– AI Mode: Generates detailed, context-aware PR titles and descriptions using OpenAI
  • ๐Ÿ“ Basic Mode: Creates simple, effective summaries based on file changes

๐Ÿš€ Quick Start

Installation

pip install ghpush

๐Ÿ’ก Check out ghpush on PyPI for the latest version and release notes.

Configuration

1. GitHub CLI Authentication (Required)

# Install GitHub CLI if you haven't already
brew install gh  # macOS
# For other platforms, see: https://cli.github.com/

# Authenticate with GitHub
gh auth login

2. Choose Operating Mode

GHPush operates in two modes:

๐Ÿค– AI Mode (Recommended)

To enable AI-powered summaries:

# Linux/macOS
export OPENAI_API_KEY=your-api-key-here

# Windows (PowerShell)
$env:OPENAI_API_KEY="your-api-key-here"
๐Ÿ“ Basic Mode
  • Automatically used when OpenAI API key is not set
  • No configuration needed
  • Provides simple summaries based on changed files

Usage

ghpush --base main

That's it! GHPush will:

  1. ๐Ÿ“ Analyze your changes
  2. ๐Ÿค– Generate a PR title and description (AI or Basic mode)
  3. ๐Ÿ”„ Push your branch
  4. ๐ŸŒ Open the PR creation page

๐Ÿ’ก Tip: Make sure you've authenticated with GitHub CLI (gh auth login) before using GHPush.

โœจ Features

  • ๐Ÿ”„ Dual Operation Modes:
    • AI-Powered Mode: Rich, contextual PR summaries using OpenAI
    • Basic Mode: Simple, effective change summaries
  • ๐Ÿš€ Automated Workflow: Push your branch and open GitHub's PR page in one command
  • ๐Ÿ“Š Smart Diff Analysis: Intelligent analysis of your code changes
  • ๐Ÿ”’ No GitHub Token Needed: Works with your local git configuration
  • ๐ŸŒ Cross-Platform: Seamless experience on Windows, macOS, and Linux

๐Ÿ›  Technical Requirements

  • Python โ‰ฅ 3.11
  • Dependencies:

๐Ÿค Contributing

We love contributions! Here's how you can help:

๐Ÿ› ๏ธ Development Setup

  1. Clone the repository:
git clone https://github.com/sukeesh/ghpush
cd ghpush
  1. Set up Python environment:

Using pyenv (Recommended)

# Install Python 3.11.9
pyenv install 3.11.9

# Create a virtual environment
pyenv virtualenv 3.11.9 ghpush-dev

# Activate the environment
pyenv activate ghpush-dev

Using venv (Alternative)

python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
  1. Install dependencies:
pip install -e .
  1. Run locally:
# Using Python module directly (recommended for development)
python -m ghpush.cli --base main

# Or after installing in development mode
ghpush --base main

๐Ÿ’ก Note: Using pyenv is recommended as it provides better Python version management and isolation.

๐Ÿ”„ Contribution Steps

  1. ๐Ÿด Fork the repository
  2. ๐ŸŒฟ Create your feature branch (git checkout -b feature/amazing-feature)
  3. ๐Ÿ’ป Make your changes
  4. โœ… Ensure tests pass
  5. ๐Ÿ“ Update documentation if needed
  6. ๐Ÿ”„ Create a pull request

๐Ÿงช Testing

# Install test dependencies
pip install pytest

# Run tests
pytest

๐Ÿ“ License

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

๐ŸŒŸ Show Your Support

If you find GHPush useful, please consider:

  • โญ Starring the repository
  • ๐Ÿ› Reporting issues
  • ๐Ÿค Contributing to the code
  • ๐Ÿ“ข Spreading the word

Made by Sukeesh

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

ghpush-0.1.8.tar.gz (13.1 kB view details)

Uploaded Source

Built Distribution

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

ghpush-0.1.8-py3-none-any.whl (12.8 kB view details)

Uploaded Python 3

File details

Details for the file ghpush-0.1.8.tar.gz.

File metadata

  • Download URL: ghpush-0.1.8.tar.gz
  • Upload date:
  • Size: 13.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for ghpush-0.1.8.tar.gz
Algorithm Hash digest
SHA256 4e618fa854d8bf10b471a2da1088fe6d18c7fffcbb31749a2baf41c6c64e43fb
MD5 da370a33d72f912081f40911f43a4d0b
BLAKE2b-256 8102b6a40b64eda33a56cc317b2c5d31788292c4ef3c863c65f38f85dd9260ec

See more details on using hashes here.

File details

Details for the file ghpush-0.1.8-py3-none-any.whl.

File metadata

  • Download URL: ghpush-0.1.8-py3-none-any.whl
  • Upload date:
  • Size: 12.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for ghpush-0.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 0d66a77b6096e5d40cfd48273adcd7eee2e97b6182c9c3bfecd60cf042c61f39
MD5 da925160481b2903a41c96af24289bb4
BLAKE2b-256 05dd2b902c9591f43f480254bdae1b3e90a3a7e60c3eb394eaa6ddc5e1bd12b7

See more details on using hashes here.

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