DescriptionSplit out the big chromite shell 'main.py' into lots of subfiles.
Main focus for review should be organization / naming. Make sure
those are OK. Since this is hard to follow, a high-level description
of things that happened here:
1. Almost everything moved out of 'main.py'. The 'utils.py' became a
bit of a dumping ground (for now) for functions needed by multiple
modules.
2. All subcommands went into the 'subcmds' folder. Mostly I have one
command per file, except for the portage commands (which are all
wrappers).
3. To make mox work better, we now import cros_build_lib directly (as
cros_lib). Now, we can mox out cros_lib.Die.
4. Cleaned up how the "--resume-state" gets handled for EnterChroot.
It's now abstracted into its own function (so that it can be in the
same file as EnterChroot).
5. Moved 'WrappedChrootCmd' into subcmd.py.
6. (Minor) Hack sys.argv[0] as 'chromite' so that help commands look
better.
Change-Id: I19aad2a437864d364f4df70236ab84bfeba35376
BUG=chromium-os:10556
TEST=Ran unit tests; built mario; tried shell; tried workon command.
Committed: http://chrome-svn/viewvc/chromeos?view=rev&revision=a9b1090
Patch Set 1 #
Total comments: 33
Patch Set 2 : Incorporated davidjames and sosa feedback. #
Messages
Total messages: 4 (0 generated)
|