/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to breezy/git/workingtree.py

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2019-06-04 00:08:59 UTC
  • mfrom: (7122.6.12 win-symlink-warning)
  • Revision ID: breezy.the.bot@gmail.com-20190604000859-2xwms4tkctrj83dm
Allow symbolic links to exist when checking out trees on Windows.

Merged from https://code.launchpad.net/~jelmer/brz/win-symlink-warning/+merge/363900

Show diffs side-by-side

added added

removed removed

Lines of Context:
414
414
        # expand any symlinks in the directory part, while leaving the
415
415
        # filename alone
416
416
        # only expanding if symlinks are supported avoids windows path bugs
417
 
        if osutils.has_symlinks():
 
417
        if self.supports_symlinks():
418
418
            file_list = list(map(osutils.normalizepath, file_list))
419
419
 
420
420
        conflicts_related = set()
742
742
 
743
743
    def is_executable(self, path):
744
744
        with self.lock_read():
745
 
            if getattr(self, "_supports_executable",
746
 
                       osutils.supports_executable)():
 
745
            if self._supports_executable():
747
746
                mode = self._lstat(path).st_mode
748
747
            else:
749
748
                (index, subpath) = self._lookup_index(path.encode('utf-8'))
754
753
            return bool(stat.S_ISREG(mode) and stat.S_IEXEC & mode)
755
754
 
756
755
    def _is_executable_from_path_and_stat(self, path, stat_result):
757
 
        if getattr(self, "_supports_executable",
758
 
                   osutils.supports_executable)():
759
 
            return self._is_executable_from_path_and_stat_from_stat(
760
 
                path, stat_result)
 
756
        if self._supports_executable():
 
757
            return self._is_executable_from_path_and_stat_from_stat(path, stat_result)
761
758
        else:
762
759
            return self._is_executable_from_path_and_stat_from_basis(
763
760
                path, stat_result)
1165
1162
            self.store,
1166
1163
            None
1167
1164
            if self.branch.head is None
1168
 
            else self.store[self.branch.head].tree)
 
1165
            else self.store[self.branch.head].tree,
 
1166
            honor_filemode=self._supports_executable())
1169
1167
 
1170
1168
    def reset_state(self, revision_ids=None):
1171
1169
        """Reset the state of the working tree.