Announcing Create a Pull Request in Visual Studio
We heard from you that you can do 90% of your development workflow in Visual Studio, but then need to rely on the web to create your pull requests. We’re continually bringing productivity enhancements to Visual Studio and are excited to announce that as of 17.7 preview 2 release. You can now create a pull request without leaving the development environment.
Creating a Pull Request
We’ve been working on integrating more GitHub and Azure DevOps features into the git tooling to supercharge your productivity and collaboration. We know pull requests are highly utilized for code review in both open source and enterprise environments. We hope that wherever and however you work, this new feature will fit into your workflow and help you become more productive than ever.
Turn on the feature flag
To make sure you can try out the feature, ensure it’s enabled in Tools > Options > Preview Features > Git Pull Request
The basic flow follows these steps:
- Create a New Branch. Before you can create a pull request, you’ll need to create a new branch for your changes. This keeps your modifications separate from the main branch until they’re ready to be merged.
- Commit and Push Your Changes. Then, you can commit and push your changes as you normally would in the Git Changes window.
- Create a Pull Request. Click the link in the notification banner to “Create a Pull Request.” Alternatively, you can create pull request from a remote branch by navigating to the New Pull Request window via the top-level menu Git > GitHub or Azure DevOps > New Pull Request. Or right click a branch in the Git Repository Window.
- Select the branch that you want to merge into the original repository and give your pull request a descriptive title and description. The diff view on the right allows you to see all your changes as you’re typing.
- You can link work items by referencing them with the issue search, by typing # in the description box or pressing the # button in the lower right corner. We’re currently working on adding support for reviewers. Once you’ve created your pull request, other developers can review your changes and provide feedback.
- Making Updates and Edits: One of our current limitations means you’ll need to use the web interface to make additional edits to the title, description, reviewers, and linked work items. Once you push new changes to your branch, they will automatically update the pull request in the web.
As a highly requested integration, the process of developing the pull request experience is an ongoing collaborative effort between our development team and the Visual Studio community. We received a lot of feedback from users who were looking for a more streamlined way to create pull requests, and we performed a series of user studies and survey rounds to get at the primary pain points in this experience.
We’re not done with the pull request experience, and we need your feedback to help drive our development. Some of our next steps include:
- Allowing users to add reviewers and required reviewers
- Markdown support for the description box
- Viewing and tracking your pull requests inside Visual Studio
Please share your thoughts on the feature, and what you’re looking forward to the most in this survey.