| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright 2013 the V8 project authors. All rights reserved. | 2 # Copyright 2013 the V8 project authors. All rights reserved. |
| 3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
| 4 # modification, are permitted provided that the following conditions are | 4 # modification, are permitted provided that the following conditions are |
| 5 # met: | 5 # met: |
| 6 # | 6 # |
| 7 # * Redistributions of source code must retain the above copyright | 7 # * Redistributions of source code must retain the above copyright |
| 8 # notice, this list of conditions and the following disclaimer. | 8 # notice, this list of conditions and the following disclaimer. |
| 9 # * Redistributions in binary form must reproduce the above | 9 # * Redistributions in binary form must reproduce the above |
| 10 # copyright notice, this list of conditions and the following | 10 # copyright notice, this list of conditions and the following |
| (...skipping 277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 | 288 |
| 289 def Land(self): | 289 def Land(self): |
| 290 raise NotImplementedError() | 290 raise NotImplementedError() |
| 291 | 291 |
| 292 def CLLand(self): | 292 def CLLand(self): |
| 293 raise NotImplementedError() | 293 raise NotImplementedError() |
| 294 | 294 |
| 295 # TODO(machenbach): There is some svn knowledge in this interface. In svn, | 295 # TODO(machenbach): There is some svn knowledge in this interface. In svn, |
| 296 # tag and commit are different remote commands, while in git we would commit | 296 # tag and commit are different remote commands, while in git we would commit |
| 297 # and tag locally and then push/land in one unique step. | 297 # and tag locally and then push/land in one unique step. |
| 298 def Tag(self, tag): | 298 def Tag(self, tag, remote): |
| 299 raise NotImplementedError() | 299 raise NotImplementedError() |
| 300 | 300 |
| 301 | 301 |
| 302 class GitSvnInterface(VCInterface): | 302 class GitSvnInterface(VCInterface): |
| 303 def Pull(self): | 303 def Pull(self): |
| 304 self.step.GitSVNRebase() | 304 self.step.GitSVNRebase() |
| 305 | 305 |
| 306 def Fetch(self): | 306 def Fetch(self): |
| 307 self.step.GitSVNFetch() | 307 self.step.GitSVNFetch() |
| 308 | 308 |
| (...skipping 26 matching lines...) Expand all Loading... |
| 335 | 335 |
| 336 def RemoteBranch(self, name): | 336 def RemoteBranch(self, name): |
| 337 return "svn/%s" % name | 337 return "svn/%s" % name |
| 338 | 338 |
| 339 def Land(self): | 339 def Land(self): |
| 340 self.step.GitSVNDCommit() | 340 self.step.GitSVNDCommit() |
| 341 | 341 |
| 342 def CLLand(self): | 342 def CLLand(self): |
| 343 self.step.GitDCommit() | 343 self.step.GitDCommit() |
| 344 | 344 |
| 345 def Tag(self, tag): | 345 def Tag(self, tag, remote): |
| 346 self.step.GitSVNFetch() |
| 347 self.step.Git("rebase %s" % remote) |
| 346 self.step.GitSVNTag(tag) | 348 self.step.GitSVNTag(tag) |
| 347 | 349 |
| 348 | 350 |
| 349 class GitReadOnlyMixin(VCInterface): | 351 class GitReadOnlyMixin(VCInterface): |
| 350 def Pull(self): | 352 def Pull(self): |
| 351 self.step.GitPull() | 353 self.step.GitPull() |
| 352 | 354 |
| 353 def Fetch(self): | 355 def Fetch(self): |
| 354 self.step.Git("fetch") | 356 self.step.Git("fetch") |
| 355 | 357 |
| (...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 836 for (number, step_class) in enumerate(step_classes): | 838 for (number, step_class) in enumerate(step_classes): |
| 837 steps.append(MakeStep(step_class, number, self._state, self._config, | 839 steps.append(MakeStep(step_class, number, self._state, self._config, |
| 838 options, self._side_effect_handler)) | 840 options, self._side_effect_handler)) |
| 839 for step in steps[options.step:]: | 841 for step in steps[options.step:]: |
| 840 if step.Run(): | 842 if step.Run(): |
| 841 return 0 | 843 return 0 |
| 842 return 0 | 844 return 0 |
| 843 | 845 |
| 844 def Run(self, args=None): | 846 def Run(self, args=None): |
| 845 return self.RunSteps(self._Steps(), args) | 847 return self.RunSteps(self._Steps(), args) |
| OLD | NEW |