Changeset 51893 in webkit
- Timestamp:
- Dec 9, 2009 1:24:40 AM (14 years ago)
- Location:
- trunk/WebKitTools
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKitTools/ChangeLog
r51891 r51893 1 2009-12-09 Adam Barth <abarth@webkit.org> 2 3 Reviewed by Eric Seidel. 4 5 [bzt] Convert Build to use Sequence 6 https://bugs.webkit.org/show_bug.cgi?id=32310 7 8 So much prettier. 9 10 * Scripts/modules/buildsteps.py: 11 * Scripts/modules/commands/download.py: 12 * Scripts/modules/landingsequence.py: 13 * Scripts/modules/stepsequence.py: Added. 14 1 15 2009-12-09 Adam Barth <abarth@webkit.org> 2 16 -
trunk/WebKitTools/Scripts/modules/buildsteps.py
r51889 r51893 51 51 52 52 class AbstractStep(object): 53 def __init__(self, tool, options ):53 def __init__(self, tool, options, patch=None): 54 54 self._tool = tool 55 55 self._options = options 56 self._patch = patch 56 57 self._port = None 57 58 … … 75 76 76 77 77 class AbstractPatchStep(AbstractStep):78 def __init__(self, tool, options, patch):79 AbstractStep.__init__(self, tool, options)80 self._patch = patch81 82 83 78 class PrepareChangelogStep(AbstractStep): 84 79 def run(self): … … 87 82 88 83 class CleanWorkingDirectoryStep(AbstractStep): 89 def __init__(self, tool, options, allow_local_commits=False):90 AbstractStep.__init__(self, tool, options )84 def __init__(self, tool, options, patch=None, allow_local_commits=False): 85 AbstractStep.__init__(self, tool, options, patch) 91 86 self._allow_local_commits = allow_local_commits 92 87 … … 99 94 100 95 def run(self): 101 os.chdir(self._tool. _scm.checkout_root)96 os.chdir(self._tool.scm().checkout_root) 102 97 if not self._allow_local_commits: 103 98 self._tool.scm().ensure_no_local_commits(self._options.force_clean) … … 121 116 122 117 123 class ApplyPatchStep(Abstract PatchStep):118 class ApplyPatchStep(AbstractStep): 124 119 @classmethod 125 120 def options(cls): … … 198 193 199 194 200 class ClosePatchStep(Abstract PatchStep):195 class ClosePatchStep(AbstractStep): 201 196 def run(self, commit_log): 202 197 comment_text = bug_comment_from_commit_text(self._tool.scm(), commit_log) … … 204 199 205 200 206 class CloseBugStep(Abstract PatchStep):201 class CloseBugStep(AbstractStep): 207 202 @classmethod 208 203 def options(cls): -
trunk/WebKitTools/Scripts/modules/commands/download.py
r51889 r51893 34 34 35 35 from modules.bugzilla import parse_bug_id 36 from modules.buildsteps import BuildSteps, EnsureBuildersAreGreenStep, CleanWorkingDirectoryStep, UpdateStep, CheckStyleStep, PrepareChangelogStep, CleanWorkingDirectoryStep36 from modules.buildsteps import BuildSteps, EnsureBuildersAreGreenStep, CleanWorkingDirectoryStep, UpdateStep, BuildStep, CheckStyleStep, PrepareChangelogStep 37 37 from modules.changelogs import ChangeLog 38 38 from modules.comments import bug_comment_from_commit_text … … 42 42 from modules.multicommandtool import Command 43 43 from modules.processutils import ScriptError 44 45 46 class BuildSequence(LandingSequence): 47 def run(self): 48 self.clean() 49 self.update() 50 self.build() 44 from modules.stepsequence import StepSequence 51 45 52 46 … … 55 49 show_in_main_help = False 56 50 def __init__(self): 57 options = BuildSteps.cleaning_options() 58 options += BuildSteps.build_options() 59 options += BuildSteps.land_options() 60 Command.__init__(self, "Update working copy and build", "", options) 61 62 def execute(self, options, args, tool): 63 sequence = BuildSequence(None, options, tool) 64 sequence.run_and_handle_errors() 51 self._sequence = StepSequence([ 52 CleanWorkingDirectoryStep, 53 UpdateStep, 54 BuildStep 55 ]) 56 Command.__init__(self, "Update working copy and build", "", self._sequence.options()) 57 58 def execute(self, options, args, tool): 59 self._sequence.run_and_handle_errors(tool, options) 65 60 66 61 -
trunk/WebKitTools/Scripts/modules/landingsequence.py
r51890 r51893 43 43 raise NotImplementedError, "subclasses must implement" 44 44 45 45 # FIXME: This class is slowing being killed and replaced with StepSequence. 46 46 class LandingSequence: 47 47 def __init__(self, patch, options, tool):
Note: See TracChangeset
for help on using the changeset viewer.