Re: [PATCHv1 2/2] git-p4: work with a detached head

2015-10-28 Thread Luke Diamand
On 28/10/15 17:44, Junio C Hamano wrote: Luke Diamand writes: On 9 September 2015 at 22:52, Junio C Hamano wrote: Luke Diamand writes: ... def currentGitBranch(): return read_pipe("git name-rev HEAD").split("

Re: [PATCHv1 2/2] git-p4: work with a detached head

2015-09-10 Thread Luke Diamand
On 9 September 2015 at 22:52, Junio C Hamano wrote: > Luke Diamand writes: > >> def run(self, args): >> if len(args) == 0: >> self.master = currentGitBranch() >> -if len(self.master) == 0 or not

Re: [PATCHv1 2/2] git-p4: work with a detached head

2015-09-10 Thread Junio C Hamano
Luke Diamand writes: > On 9 September 2015 at 22:52, Junio C Hamano wrote: >> Luke Diamand writes: >> >>> def run(self, args): >>> if len(args) == 0: >>> self.master = currentGitBranch() >>> -if

Re: [PATCHv1 2/2] git-p4: work with a detached head

2015-09-09 Thread Junio C Hamano
Luke Diamand writes: > def run(self, args): > if len(args) == 0: > self.master = currentGitBranch() > -if len(self.master) == 0 or not gitBranchExists("refs/heads/%s" > % self.master): > -die("Detecting current git branch