Skip to content

Cmd line tool to open a Pull Request via a browser

License

Notifications You must be signed in to change notification settings

johnkors/dotnet-pr

Repository files navigation

NuGet NuGet Build

dotnet-pr

This a .NET Core Global Tool that ..

  1. Given your terminals working directory is a git repo

  2. That git repo has a remote that is a code collaboration tool (ex. origin -> GitHub/BitBucket/GitLab/Azure DevOps)

  3. Opens your default browser in the Pull Request UI for the current branch in the tool connected to the remote branch.

Installation

  • Running the tool: .NET 7 or 8
  • Development: .NET 8 SDK

Install

$ dotnet tool install dotnet-pr -g

Usage

After install, navigate to a git repo and call pr from the terminal.

Optional arguments

  • debug output
$ pr --debug
  • Target the PR towards another branch than master (default)
$ pr <your-target-branch-here>

Supported PR tools

  • github.com
  • bitbucket.org
  • gitlab.com
  • dev.azure.com (Azure DevOps, dev.azure.com/{org})
  • dev.azure.com (Azure DevOps Private, {org}.visualstudio.com)
  • (Bitbucket (Self-Hosted))