Bug 794509 - Part 2: Move mach command modules into a mach.commands sub-module; r=jhammel

This patch on its own will break mach. Part 3 will refactor mach's
loader to discover and load modules using a modified module finding
method.

--HG--
rename : python/mach/mach/settings.py => python/mach/mach/commands/settings.py
rename : python/mach/mach/build.py => python/mozbuild/mach/commands/build.py
rename : python/mach/mach/testing.py => python/mozbuild/mach/commands/testing.py
rename : python/mach/mach/warnings.py => python/mozbuild/mach/commands/warnings.py
This commit is contained in:
Gregory Szorc 2012-10-05 12:13:18 -07:00
parent bc9c3745e8
commit 5385e05615
10 changed files with 5 additions and 7 deletions

1
mach
View File

@ -38,7 +38,6 @@ our_dir = os.path.dirname(os.path.abspath(__file__))
try:
import mach.main
except ImportError:
SEARCH_PATHS.reverse()
sys.path[0:0] = [os.path.join(our_dir, path) for path in SEARCH_PATHS]
import mach.main

View File

View File

@ -22,11 +22,10 @@ from mach.registrar import populate_argument_parser
# Import sub-command modules
# TODO Bug 794509 do this via auto-discovery. Update README once this is
# done.
from mach.build import Build
from mach.settings import Settings
from mach.testing import Testing
from mach.warnings import Warnings
from mach.commands.build import Build
from mach.commands.settings import Settings
from mach.commands.testing import Testing
from mach.commands.warnings import Warnings
# Classes inheriting from ConfigProvider that provide settings.
# TODO this should come from auto-discovery somehow.

View File

View File

@ -10,6 +10,6 @@ setup(
name='mozbuild',
description='Mozilla build system functionality.',
license='MPL 2.0',
packages=['mozbuild'],
packages=['mach', 'mozbuild'],
version=VERSION
)