Crates.io | ghpr |
lib.rs | ghpr |
version | 0.2.0 |
source | src |
created_at | 2024-10-16 23:50:48.489635 |
updated_at | 2024-10-21 20:52:46.249315 |
description | Generates GitHub pull request URLs |
homepage | https://www.github.com/ArunVenkata/ghpr |
repository | https://www.github.com/ArunVenkata/ghpr |
max_upload_size | |
id | 1412463 |
size | 55,421 |
Welcome to the GitHub PR URL Generator! This command-line tool simplifies the creation of pull request for your GitHub repositories.
To create a PR quickly, run the command and click the generated link.
Here are some examples of how to use the ghpr
command:
ghpr --repo owner/repo --src my-feature-branch --dest main
ghpr --repo owner/repo --src main --dest feature-branch --title "Fix bug" --body "This PR fixes the bug."
.ghprrc
file (destination is picked up from the file):ghpr --src feature-branch --title "Add new feature"
.ghprrc file:
[defaults]
dest="master"
repo="ArunVenkata/ghpr"
Generated URL: https://github.com/ArunVenkata/ghpr/compare/feature-branch...master?quick_pull=1&title=Add%20new%20feature
Ensure you have Rust installed on your machine.
Run the following command
cargo install ghpr
git clone https://github.com/ArunVenkata/ghpr.git
cd ghpr
Ensure you have Rust installed on your machine.
Build the project:
cargo build --release
./target/release/ghpr --help
The .ghprrc file allows you to set default values for various parameters used in the ghpr command. This file should be located in your project directory and formatted as follows:
[defaults]
repo = "owner/repo"
src = "feature-branch"
dest = "main"
title = "Your PR Title"
body = "Description of the pull request."
labels = "bug,enhancement"
milestone = "1.0"
assignees = "username1,username2"
projects = "project1,project2"
template = "template_name"
Note: If
src
is not specified, it automatically refers to your current git branch (provided your current directory is a git repository)
Run ghpr --help
for more information on the supported parameters.
If you would like to contribute to the project, please follow these guidelines:
git checkout -b feature/new-feature
git commit -m "Add some feature"
git push origin feature/new-feature
Open a pull request and describe your changes.
This project is licensed under the MIT License. See the LICENSE file for details.