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

Side by Side Diff: checkout.py

Issue 10967071: Fix applying svn:executable on Windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 8 years, 2 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 | « no previous file | patch.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # coding=utf8 1 # coding=utf8
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 """Manages a project checkout. 5 """Manages a project checkout.
6 6
7 Includes support for svn, git-svn and git. 7 Includes support for svn, git-svn and git.
8 """ 8 """
9 9
10 import ConfigParser 10 import ConfigParser
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after
359 if value is None: 359 if value is None:
360 stdout += self._check_output_svn( 360 stdout += self._check_output_svn(
361 ['propdel', '--quiet', name, p.filename], credentials=False) 361 ['propdel', '--quiet', name, p.filename], credentials=False)
362 else: 362 else:
363 stdout += self._check_output_svn( 363 stdout += self._check_output_svn(
364 ['propset', name, value, p.filename], credentials=False) 364 ['propset', name, value, p.filename], credentials=False)
365 for prop, values in self.svn_config.auto_props.iteritems(): 365 for prop, values in self.svn_config.auto_props.iteritems():
366 if fnmatch.fnmatch(p.filename, prop): 366 if fnmatch.fnmatch(p.filename, prop):
367 for value in values.split(';'): 367 for value in values.split(';'):
368 if '=' not in value: 368 if '=' not in value:
369 params = [value, '*'] 369 params = [value, '.']
370 else: 370 else:
371 params = value.split('=', 1) 371 params = value.split('=', 1)
372 if params[1] == '*':
373 # Works around crbug.com/150960 on Windows.
374 params[1] = '.'
372 stdout += self._check_output_svn( 375 stdout += self._check_output_svn(
373 ['propset'] + params + [p.filename], credentials=False) 376 ['propset'] + params + [p.filename], credentials=False)
374 for post in post_processors: 377 for post in post_processors:
375 post(self, p) 378 post(self, p)
376 except OSError, e: 379 except OSError, e:
377 raise PatchApplicationFailed(p, '%s%s' % (stdout, e)) 380 raise PatchApplicationFailed(p, '%s%s' % (stdout, e))
378 except subprocess.CalledProcessError, e: 381 except subprocess.CalledProcessError, e:
379 raise PatchApplicationFailed( 382 raise PatchApplicationFailed(
380 p, 383 p,
381 'While running %s;\n%s%s' % ( 384 'While running %s;\n%s%s' % (
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
646 def revisions(self, rev1, rev2): 649 def revisions(self, rev1, rev2):
647 return self.checkout.revisions(rev1, rev2) 650 return self.checkout.revisions(rev1, rev2)
648 651
649 @property 652 @property
650 def project_name(self): 653 def project_name(self):
651 return self.checkout.project_name 654 return self.checkout.project_name
652 655
653 @property 656 @property
654 def project_path(self): 657 def project_path(self):
655 return self.checkout.project_path 658 return self.checkout.project_path
OLDNEW
« no previous file with comments | « no previous file | patch.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698