lp:~niemeyer/pyjuju/go-simpler-supercommand

Created by Gustavo Niemeyer and last modified
Get this branch:
bzr branch lp:~niemeyer/pyjuju/go-simpler-supercommand
Only Gustavo Niemeyer can upload to this branch. If you are Gustavo Niemeyer please log in for upload directions.

Branch merges

Related bugs

Related blueprints

Branch information

Owner:
Gustavo Niemeyer
Project:
pyjuju
Status:
Development

Recent revisions

128. By Gustavo Niemeyer

cmd: simpler SuperCommand logic

This is a strawman. Tests are broken.

127. By Roger Peppe

state: make ssh testing key private

This fixes an SSH error when SSH detects that it's
using a private key that is publicly accessible.

R=fwereade, niemeyer
CC=
https://codereview.appspot.com/6095048

126. By Roger Peppe

environs/ec2: make tests work without AWS_* environment variables.

R=niemeyer
CC=
https://codereview.appspot.com/6075043

125. By William Reade

Add cmd.Context type to enable output capture and environment control

In order to run a Command inside another process, the host process needs to
know the client's working directory (for relative file paths), and it needs
separate output streams (so that it goes where it's intended).

The only impact on existing Commands is that their Run method now expects a
*cmd.Context; the only command that's materially affected is SuperCommand,
which becomes slightly simpler (because logging setup is now the
responsibility of the Context; SuperCommand just parses the args and hands
them over).

FlagSets are now always constructed with ContinueOnError, and with
configurable output; this unifies error handling and usage printing (there's
now only one code path for each), and allows us to correctly print usage for
commands that don't have any sensible options (eg open-port). As a
side-effect, it's much simpler to test command-line parsing for arbitrary
commands, because errors no longer cause os.Exit to be called. For clarity's
sake, pre-existing tests have been left untouched; expect a followup branch
that tidies up main and main_test in juju and jujud.

PrintUsage and NewFlagSet are now private (in addition to expecting an
io.Writer for output), because they weren't used externally in the first
place, and in practice were just dirtying up the interface.

R=niemeyer, rog
CC=
https://codereview.appspot.com/5758050

124. By Roger Peppe



state: add ssh forwarding functionality

R=niemeyer, fwereade
CC=
https://codereview.appspot.com/5970053

123. By Frank Mueller

Implemented the NeedsUpgradeWatcher for Units.

It's based on the changed ContentWatcher. Also the tests have
been harmonized (better timeout handling).

R=
CC=
https://codereview.appspot.com/6050053

122. By Gustavo Niemeyer

store: fix stats=0 handling for /charm/

R=rog
CC=
https://codereview.appspot.com/6072046

121. By Frank Mueller

Small ConfigWatcher change.

Only applying the ContentWatcher changes to the ConfigWatcher.

R=niemeyer
CC=
https://codereview.appspot.com/6056047

120. By Frank Mueller

Enhanced ContentWatcher to watch also creation and deletion.

Instead of a simple content string now a struct with an additional
bool field for existance is emitted.

R=niemeyer
CC=
https://codereview.appspot.com/6059044

119. By Gustavo Niemeyer

store: serve 42 on specific path to run perf tests with blitz.io

R=rog, fwereade
CC=
https://codereview.appspot.com/6049044

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
Stacked on:
lp:pyjuju
This branch contains Public information 
Everyone can see this information.

Subscribers