← Back to team overview

launchpad-dev team mailing list archive

Re: Finding the right 'bzr' at runtime for 'lp-forking-service'

 

On Nov 24, 2010, at 11:38 AM, Jonathan Lange wrote:

> On Wed, Nov 24, 2010 at 4:34 PM, John Arbash Meinel
> <john.meinel@xxxxxxxxxxxxx> wrote:
> ...
>> I've posted to the RT request an init script that does the 'less
>> tasteful' way. ATM init scripts are not in the launchpad codebase, and
>> exist somewhere I'm not quite sure of.
> 
> I don't know either.

They are in the eggs themselves.

AFAICT, buildout does not have a good story for these sorts of distutils scripts.

This is a way that I'd expect to run bzr:

{{{
import pkg_resources

bzr_distribution = pkg_resources.get_distribution(
    pkg_resources.Requirement.parse('bzr'))

bzr_distribution.run_script('bzr', globals().copy())
}}}

I have a branch that does this using the buildout template mechanism.  If someone wants to review this--John, minimally could you verify that this does what you need?--I'll land it.

https://code.launchpad.net/~gary/launchpad/bzrbin/+merge/41770

Gary




Follow ups

References