[MERGE] Refactor loopback/paramiko/openssh/ssh connection opening
Martin Pool
mbp at canonical.com
Fri Aug 25 07:36:42 BST 2006
On 25 Aug 2006, Robert Collins <robertc at robertcollins.net> wrote:
> On Fri, 2006-08-25 at 15:54 +1000, Martin Pool wrote:
> >
> > > +def os_specific_subprocess_params():
> > > + """Get O/S specific subprocess parameters."""
> >
> > Could this move to an instance method of SubprocessVendor?
> >
> > It's also called from the code that runs 'ssh -V', but setting these
> > options is not really needed to get the version.
>
> I'd be wary of putting O/S things in the same hierarchy as vendor
> changes.
>
> I'd be more inclined to have parameterised vendors, with an os flavour
> class instead - that will give more combinations with less duplication.
I wasn't suggesting adding subclasses per OS - rather just that this
code only relates to ssh in a subprocess, so can be moved closer to that
point. Since it's the only thing that varies per OS we might
not need an OS flavour class for now.
--
Martin
More information about the bazaar
mailing list