/stdhome

To get this branch, use:
bzr branch http://bzr.ed.am/stdhome

« back to all changes in this revision

Viewing changes to lib/stdhome/walker/walker.py

  • Committer: Tim Marston
  • Date: 2014-07-23 18:47:26 UTC
  • Revision ID: tim@ed.am-20140723184726-plcl9oe1z97durta
during add, ensure parent directories are added

Show diffs side-by-side

added added

removed removed

Lines of Context:
38
38
                walk_list that fall under the directory are skipped.
39
39
                """
40
40
 
41
 
                if the.verbose >= 3: print "walking [%s]" % self.__class__.__name__
42
 
 
43
41
                skip = ''
 
42
 
44
43
                for rel_file in self.walk_list:
45
44
 
46
45
                        # if we're skipping, skip entries in subdirectories, or turn off
62
61
                        # way of knowing what to check.  It could be src_type or dst_type
63
62
                        # (if src_dir or dst_dir was used to generate the walk list) or it
64
63
                        # could be neither (if the walk list came from somewhere else).  But
65
 
                        # it shouldn't matter: we add a path seperateor (os.sep) to the end
66
 
                        # of the filename, so it wuill only match files that are descendents
67
 
                        # of a directory with the name of this file.
 
64
                        # it shouldn't matter.  We adding an os.pathset to the end of the
 
65
                        # filename, so it wuill only match files that are descendents of a
 
66
                        # directory with the name of this file.
68
67
                        if not recurse: skip = rel_file + os.sep
69
68
 
70
69
 
109
108
                if full_dir is None: full_dir = the.repo.full_dir
110
109
 
111
110
                # ignore some files
112
 
                if rel_file in [ '.bzr', '.bzrignore', '.stdhome', '.stdhomerc' ]:
 
111
                if rel_file in { '.bzr', '.bzrignore', '.stdhome', '.stdhomerc' }:
113
112
                        return list()
114
113
 
115
114
                full_file = os.path.join( full_dir, rel_file )