For most development teams, the final step in the development process is a pull request and CodeStream allows you to keep that workflow inside your IDE. The Pull Requests section of the CodeStream pane lists all open pull requests that are relevant to you.
Pull request creation is available for GitHub, GitHub Enterprise, GitLab, GitLab Self-Managed, Bitbucket, and Bitbucket Server. Pull request review is only available for GitHub, GitHub Enterprise, GitLab, and GitLab Self-Managed.
The pull request section seperates PRs by those waiting for review, those assigned to you, those created by you, and the most recent PRs.
Click on any pull request in the list to edit, review or even merge the code. You’ll see the pull request get expanded in a tree view that provides access to the pull request’s details, as well as all of the files that were changed. The things that you do most frequently… adding and viewing comments… are easily accessible. Just click on any file to open the diff and start reviewing the changes.
You can use your IDE’s built-in diff navigation to move between the changes in a file. Select a block of code to add a comment. Note that CodeStream allows you to comment on lines of code that aren't part of the changeset. These comments are added as a single comment ("comment now" in GitLab's vernacular) to the pull request and aren't part of any review you may have in progress.
In VS Code, you’ll see a comment button appear over in the CodeStream pane.
In a JetBrains IDE you’ll see a comment button appear in the diff gutter, and clicking it will allow you to comment right in the editor.
As you add comments they’ll appear nested under the appropriate file in the tree view, making it easy for you, and the pull request’s author, to get at them.
Clicking on a comment will open the discussion and scroll you to the corresponding block of code in the diff.
Need to make a requested change? Just click “Open Local File” to go straight to where you need to do your work. Or click “Show Comment in Diff” just to its left to jump to the location for any other comments in the current file.
As you work your way through the files in the pull request, click the circle to mark a file as viewed. And when you're done, click the green Review button to submit the review.
Click the PR Details entry in the tree to manage the pull request. You’ll see an interface just like what you’re used to seeing on GitHub (as depicted below) or on GitLab, so the mechanisms for changing a pull requests reviewers, assignees, and labels should be very familiar.
By default, you'll see your pull requests broken out into the following sections, which are really just default queries:
- Waiting on My Review: Open pull requests where you are a reviewer, or a requested reviewer.
- Assigned to Me: Open pull requests assigned to you.
- Created by Me: Open pull requests created by you.
- Recent: The five most recent pull requests created by you, regardless of status.
When you hover over a pull request's row you'll see options to view the pull request on your code-hosting service, copy the pull request's URL, checkout the branch, and refresh the pull request to make sure what you're looking at is up to date.
Hover over any section's heading for options to refresh the list pull requests in that section, edit the section's query, or to delete the section.
If you want to view, or review, a pull request that isn't in your list just grab the URL and then click on the Load PR from URL section.Paste in the URL and you can view the pull request right inside CodeStream.
When you hover over the Pull Requests section heading, icons appear at the right.
- Refresh all the sections (or queries) at once.
- Create a new pull request.
- Create a new section based on a custom query. Note that there are some special guidelines when creating a custom query for GitHub and GitHub Enterprise or for GitLab and GitLab Self-Managed.
- Click on the gear icon for more options, including the ability to see pull requests from all repositories, and not just those associated with repositories open in your IDE, and the ability to include labels in the list. If your GitLab organization supports multiple reviewers and assignees, there's also an option to enable this.
To open a pull request at any time, click the + button at the top of the CodeStream pane or the + button in the header of the Pull Requests section. You can also use a keyboard shortcut (
p on a Mac, and
m if you're a GitLab user). CodeStream provides you with tree view, list view, and diff view options for reviewing your changes before opening the pull request.
With a single click you can name the pull request based on the last commit message, the branch name, or, if you started work by selecting a ticket, the ticket title. If you have a ticket selected, you can also explicitly tie the ticket to the pull request; CodeStream will include a link to the ticket in the pull request's description. Before submitting the pull request, review your changes by clicking on any of the files listed below the form.
If the feature branch you're working on doesn't have a remote-tracking branch, when you create a pull request, you can set your remote-tracking branch.
See also the following options to create pull requests:
By default, GitHub's search API does a global search across all of GitHub. As a result, you'll need to make sure that your query includes at least one of the following qualifiers to make sure that the result set is appropriately limited.
More details about GitHub's search syntax can be found here.
All searches are done using
attribute=value format with an
& between each parameter. For parameters with a space in them, leave them as-is and do not put quotes in the parameter (for example,
labels=foo,help wanted). You can use
@me to specify your user id and user name otherwise they can be found on GitLab. All filters, by default, have parameter
scope=all (see Minimum Qualifiers). To overwrite this, use
scope=X. See the examples given below.