Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(704)

Issue 92610043: Add user infor to switch

Can't Edit
Can't Publish+Mail
Start Review
Created:
9 years, 11 months ago by waigani
Modified:
9 years, 10 months ago
Reviewers:
mp+220868, menn0, thumper, fwereade, axw
Visibility:
Public.

Description

Add user infor to switch Append current user's username to current environment info printed out by `$ juju switch`. https://code.launchpad.net/~waigani/juju-core/switch-show-user/+merge/220868 (do not edit description out of merge proposal)

Patch Set 1 #

Total comments: 2

Patch Set 2 : Add user infor to switch #

Total comments: 2

Patch Set 3 : Add user infor to switch #

Total comments: 1

Patch Set 4 : Add user infor to switch #

Total comments: 3

Patch Set 5 : Add user infor to switch #

Patch Set 6 : Add user infor to switch #

Total comments: 21

Patch Set 7 : Add user infor to switch #

Total comments: 18

Patch Set 8 : Add user infor to switch #

Total comments: 8

Patch Set 9 : Add user infor to switch #

Unified diffs Side-by-side diffs Delta from patch set Stats (+236 lines, -33 lines) Patch
A [revision details] View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -0 lines 0 comments Download
M cmd/juju/switch.go View 1 2 3 4 5 6 7 8 6 chunks +165 lines, -33 lines 0 comments Download
M cmd/juju/switch_test.go View 1 2 3 4 5 6 7 8 3 chunks +69 lines, -0 lines 0 comments Download

Messages

Total messages: 24
waigani
Please take a look.
9 years, 11 months ago (2014-05-25 01:14:19 UTC) #1
menn0
LGTM. Nitpicks only. https://codereview.appspot.com/92610043/diff/1/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/1/cmd/juju/switch.go#newcode84 cmd/juju/switch.go:84: } This might be cleaner if ...
9 years, 11 months ago (2014-05-25 21:56:48 UTC) #2
waigani
Please take a look.
9 years, 11 months ago (2014-05-26 00:53:02 UTC) #3
thumper
https://codereview.appspot.com/92610043/diff/20001/cmd/juju/switch_test.go File cmd/juju/switch_test.go (right): https://codereview.appspot.com/92610043/diff/20001/cmd/juju/switch_test.go#newcode24 cmd/juju/switch_test.go:24: User: "joblow", Can we just use "joe" here? For ...
9 years, 11 months ago (2014-05-26 01:05:42 UTC) #4
waigani
Please take a look.
9 years, 11 months ago (2014-05-26 01:43:02 UTC) #5
thumper
https://codereview.appspot.com/92610043/diff/40001/cmd/juju/switch_test.go File cmd/juju/switch_test.go (right): https://codereview.appspot.com/92610043/diff/40001/cmd/juju/switch_test.go#newcode65 cmd/juju/switch_test.go:65: c.Assert(testing.Stdout(context), gc.Equals, "erewhemos as user "+testCreds.User+"\n") As I mentioned ...
9 years, 11 months ago (2014-05-26 01:46:37 UTC) #6
waigani
On 2014/05/26 01:46:37, thumper wrote: > https://codereview.appspot.com/92610043/diff/40001/cmd/juju/switch_test.go > File cmd/juju/switch_test.go (right): > > https://codereview.appspot.com/92610043/diff/40001/cmd/juju/switch_test.go#newcode65 > ...
9 years, 11 months ago (2014-05-26 03:16:56 UTC) #7
waigani
Please take a look.
9 years, 11 months ago (2014-05-26 03:39:14 UTC) #8
thumper
https://codereview.appspot.com/92610043/diff/60001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/60001/cmd/juju/switch.go#newcode149 cmd/juju/switch.go:149: if username != "" { Hmm... is this implied ...
9 years, 11 months ago (2014-05-26 04:09:43 UTC) #9
waigani
Please take a look.
9 years, 11 months ago (2014-05-26 04:23:37 UTC) #10
waigani
https://codereview.appspot.com/92610043/diff/60001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/60001/cmd/juju/switch.go#newcode149 cmd/juju/switch.go:149: if username != "" { On 2014/05/26 04:09:42, thumper ...
9 years, 11 months ago (2014-05-26 04:25:17 UTC) #11
fwereade
I'm not convinced by this. It's a compatibility break (which is not in itself necessarily ...
9 years, 11 months ago (2014-05-26 07:26:56 UTC) #12
fwereade
On 2014/05/26 07:26:56, fwereade wrote: > I'm not convinced by this. It's a compatibility break ...
9 years, 11 months ago (2014-05-26 07:28:12 UTC) #13
waigani
Please take a look.
9 years, 11 months ago (2014-05-27 04:44:16 UTC) #14
fwereade
Coming along nicely, thanks. https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go#newcode53 cmd/juju/switch.go:53: $ juju switch --env-info Not ...
9 years, 11 months ago (2014-05-27 07:47:13 UTC) #15
menn0
Just some little things I noticed https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go#newcode76 cmd/juju/switch.go:76: # Format environment ...
9 years, 11 months ago (2014-05-27 21:16:05 UTC) #16
waigani
Please take a look. https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go#newcode53 cmd/juju/switch.go:53: $ juju switch --env-info On ...
9 years, 11 months ago (2014-05-28 00:30:47 UTC) #17
thumper
https://codereview.appspot.com/92610043/diff/110001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/110001/cmd/juju/switch.go#newcode53 cmd/juju/switch.go:53: $ juju switch --env-info Why is this not just: ...
9 years, 11 months ago (2014-05-28 02:26:46 UTC) #18
fwereade
quick comments while I can, I'll try to do some more before you get online ...
9 years, 11 months ago (2014-05-28 16:01:41 UTC) #19
menn0
https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/90001/cmd/juju/switch.go#newcode251 cmd/juju/switch.go:251: return username, nil On 2014/05/28 16:01:41, fwereade wrote: > ...
9 years, 11 months ago (2014-05-28 21:20:34 UTC) #20
axw
https://codereview.appspot.com/92610043/diff/110001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/110001/cmd/juju/switch.go#newcode53 cmd/juju/switch.go:53: $ juju switch --env-info On 2014/05/28 02:26:46, thumper wrote: ...
9 years, 11 months ago (2014-05-29 03:05:06 UTC) #21
waigani
Please take a look. https://codereview.appspot.com/92610043/diff/110001/cmd/juju/switch.go File cmd/juju/switch.go (right): https://codereview.appspot.com/92610043/diff/110001/cmd/juju/switch.go#newcode45 cmd/juju/switch.go:45: # Show current environment name ...
9 years, 11 months ago (2014-05-30 01:52:36 UTC) #22
fwereade
Nearly there, I think it just needs another pass to rework printEnvInfo. I have a ...
9 years, 11 months ago (2014-06-02 08:56:03 UTC) #23
waigani
9 years, 10 months ago (2014-06-03 00:51:04 UTC) #24
Please take a look.

https://codereview.appspot.com/92610043/diff/130001/cmd/juju/switch.go
File cmd/juju/switch.go (right):

https://codereview.appspot.com/92610043/diff/130001/cmd/juju/switch.go#newcod...
cmd/juju/switch.go:119: c.EnvInfo = c.out.Name() != "simple"
On 2014/06/02 08:56:03, fwereade wrote:
> -1 on this. Can't we always grab the same information, and define a formatter
> that outputs the subset we want in the style we want?

Done. Actually, the current "simple" formatter already only prints out a subset.
So I can simply remove c.EnvInfo.

https://codereview.appspot.com/92610043/diff/130001/cmd/juju/switch.go#newcod...
cmd/juju/switch.go:266: return nil, nil
On 2014/06/02 08:56:03, fwereade wrote:
> return an actual error here please

Done.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b