On 2010-05-27, Martin Jansa wrote:
> On Thu, May 27, 2010 at 04:20:01PM +0000, Florian Schlichting wrote:
>> --- a/Makefile
>> +++ b/Makefile
>> @@ -234,7 +234,7 @@ shr-unstable/.configured: common/.git/config
>> bitbake/.git/config openembedded/.g
>> [ -e shr-unstable/openembedded ] || ( cd shr-unstable ; \
>> git clone --reference ../openembedded
>> git://git.openembedded.net/openembedded openembedded; \
>> cd openembedded ; \
>> - git checkout --no-track -b ${SHR_UNSTABLE_BRANCH_OE}
>> origin/${SHR_UNSTABLE_BRANCH_OE} )
>> + git checkout --no-track origin/${SHR_UNSTABLE_BRANCH_OE} ; git
>> branch -f ${SHR_UNSTABLE_BRANCH_OE} )
>> [ -d shr-unstable/conf ] || ( mkdir -p shr-unstable/conf )
>> [ -e shr-unstable/conf/site.conf ] || ( cd shr-unstable/conf ; ln
>> -sf ../../common/conf/site.conf . )
>> [ -e shr-unstable/conf/auto.conf ] || ( \
>>
>>
>> What do you think?
>
> maybe
> git checkout ${SHR_UNSTABLE_BRANCH_OE} || git checkout --no-track -b
> ${SHR_UNSTABLE_BRANCH_OE} origin/${SHR_UNSTABLE_BRANCH_OE}
>
> not sure if your solution works when SHR_UNSTABLE_BRANCH_OE is not the
> same branch as what is checkouted by default while checkouting ../openembedded
in that case, 'git checkout --no-track origin/${SHR_UNSTABLE_BRANCH_OE}'
will just check out whatever origin/${SHR_UNSTABLE_BRANCH_OE} points to,
as a detached head. That detached head will then be made a proper branch
head with git branch
I've tried your committed solution and it works, so I'm happy.
Florian
_______________________________________________
Shr-devel mailing list
[email protected]
http://lists.shr-project.org/mailman/listinfo/shr-devel