~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/externalcommand.py

  • Committer: aaron.bentley at utoronto
  • Date: 2005-09-04 02:59:56 UTC
  • mfrom: (1172)
  • mto: (1185.3.4)
  • mto: This revision was merged to the branch mainline in revision 1178.
  • Revision ID: aaron.bentley@utoronto.ca-20050904025956-776ba4f07de97700
Merged mpool's latest changes (~0.0.7)

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
 
22
22
import os
23
23
import sys
24
 
 
25
24
from bzrlib.commands import Command
26
25
 
27
26
 
34
33
        bzrpath = os.environ.get('BZRPATH', '')
35
34
 
36
35
        for dir in bzrpath.split(os.pathsep):
37
 
            ## Empty directories are not real paths
38
 
            if not dir:
39
 
                continue
40
36
            path = os.path.join(dir, cmd)
41
37
            if os.path.isfile(path):
42
38
                return ExternalCommand(path)
47
43
    def __init__(self, path):
48
44
        self.path = path
49
45
 
50
 
 
 
46
 
51
47
    def name(self):
52
48
        return self.path.split(os.sep)[-1]
53
49