diff options
| -rw-r--r-- | project.py | 6 |
1 files changed, 3 insertions, 3 deletions
| @@ -405,8 +405,8 @@ class _LinkFile(object): | |||
| 405 | else: | 405 | else: |
| 406 | src = _SafeExpandPath(self.git_worktree, self.src) | 406 | src = _SafeExpandPath(self.git_worktree, self.src) |
| 407 | 407 | ||
| 408 | if os.path.exists(src): | 408 | if not glob.has_magic(src): |
| 409 | # Entity exists so just a simple one to one link operation. | 409 | # Entity does not contain a wild card so just a simple one to one link operation. |
| 410 | dest = _SafeExpandPath(self.topdir, self.dest, skipfinal=True) | 410 | dest = _SafeExpandPath(self.topdir, self.dest, skipfinal=True) |
| 411 | # dest & src are absolute paths at this point. Make sure the target of | 411 | # dest & src are absolute paths at this point. Make sure the target of |
| 412 | # the symlink is relative in the context of the repo client checkout. | 412 | # the symlink is relative in the context of the repo client checkout. |
| @@ -414,7 +414,7 @@ class _LinkFile(object): | |||
| 414 | self.__linkIt(relpath, dest) | 414 | self.__linkIt(relpath, dest) |
| 415 | else: | 415 | else: |
| 416 | dest = _SafeExpandPath(self.topdir, self.dest) | 416 | dest = _SafeExpandPath(self.topdir, self.dest) |
| 417 | # Entity doesn't exist assume there is a wild card | 417 | # Entity contains a wild card. |
| 418 | if os.path.exists(dest) and not platform_utils.isdir(dest): | 418 | if os.path.exists(dest) and not platform_utils.isdir(dest): |
| 419 | _error('Link error: src with wildcard, %s must be a directory', dest) | 419 | _error('Link error: src with wildcard, %s must be a directory', dest) |
| 420 | else: | 420 | else: |
