reef-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Markus Weimer <>
Subject Re: A git question
Date Thu, 14 Apr 2016 20:58:19 GMT
On 4/14/2016 11:54 AM, Dhruv Mahajan wrote:
> No :( ... The remote branches have all been deleted...whats remaining is a
> pull request.

Oh wow. You also nuked your remote? That is a thorough clean :)

You can checkout an individual pull request via

$> git fetch pull/$PR/head:$branch

replace $PR with the numerical ID of the pull request and $branch with 
the name of the branch you want to create locally. Alternatively, you 
can add the following code to your PowerShell profile:

function REEF-Checkout-PullRequest{
         [Parameter(Position=0, Mandatory=$true, HelpMessage='The pull 
request numer')]
         [Parameter(Mandatory=$false, HelpMessage='The branch to check 
the PR out into')]

     $branch = if([string]::IsNullOrEmpty($B)) {"PR-$PR"} else {$B}
     Invoke-Expression "git fetch 
     Invoke-Expression "git checkout $branch"


View raw message