Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(30)

Side by Side Diff: shell/subcmds/portage_cmds.py

Issue 6250058: Split out the big chromite shell 'main.py' into lots of subfiles. (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/chromite.git@master
Patch Set: Incorporated davidjames and sosa feedback. Created 9 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « shell/subcmds/clean_cmd.py ('k') | shell/subcmds/shell_cmd.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 # Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
4
5 """Implementation of the various portage wrapper commands."""
6
7
8 from chromite.shell import subcmd
9
10
11 class EbuildCmd(subcmd.WrappedChrootCmd):
12 """Run ebuild."""
13
14 def __init__(self):
15 """EbuildCmd constructor."""
16 # Just call the WrappedChrootCmd superclass, which does most of the work.
17 super(EbuildCmd, self).__init__(
18 ['ebuild-%s'], ['ebuild'],
19 need_args=True
20 )
21
22
23 class EmergeCmd(subcmd.WrappedChrootCmd):
24 """Run emerge."""
25
26 def __init__(self):
27 """EmergeCmd constructor."""
28 # Just call the WrappedChrootCmd superclass, which does most of the work.
29 super(EmergeCmd, self).__init__(
30 ['emerge-%s'], ['sudo', 'emerge'],
31 need_args=True
32 )
33
34
35 class EqueryCmd(subcmd.WrappedChrootCmd):
36 """Run equery."""
37
38 def __init__(self):
39 """EqueryCmd constructor."""
40 # Just call the WrappedChrootCmd superclass, which does most of the work.
41 super(EqueryCmd, self).__init__(
42 ['equery-%s'], ['equery'],
43 need_args=True
44 )
45
46
47 class PortageqCmd(subcmd.WrappedChrootCmd):
48 """Run portageq."""
49
50 def __init__(self):
51 """PortageqCmd constructor."""
52 # Just call the WrappedChrootCmd superclass, which does most of the work.
53 super(PortageqCmd, self).__init__(
54 ['portageq-%s'], ['portageq'],
55 need_args=True
56 )
OLDNEW
« no previous file with comments | « shell/subcmds/clean_cmd.py ('k') | shell/subcmds/shell_cmd.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698