lp:~niemeyer/pyjuju/go-simpler-supercommand
- Get this branch:
- bzr branch lp:~niemeyer/pyjuju/go-simpler-supercommand
Branch merges
- Juju Engineering: Pending requested
-
Diff: 216 lines (+39/-89)3 files modifiedcmd/command.go (+3/-66)
cmd/context.go (+27/-2)
cmd/supercommand.go (+9/-21)
Branch information
Recent revisions
- 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). - 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