Skip to content

Commit

Permalink
Address #31
Browse files Browse the repository at this point in the history
  • Loading branch information
cpburnz committed Jan 29, 2020
1 parent 7daea29 commit 2b35f31
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,5 @@ pip-log.txt
# Sublime Text file.
*.sublime-project
*.sublime-workspace

*.iml
8 changes: 8 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@ Change History
==============


0.8.0 (TDB)
-----------

- `Issue #31`_: match_tree doesn't return symlink.

.. _`Issue #31`: https://github.com/cpburnz/python-path-specification/issues/31


0.7.0 (2019-12-27)
------------------

Expand Down
7 changes: 4 additions & 3 deletions pathspec/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
from __future__ import unicode_literals

__author__ = "Caleb P. Burns"
__copyright__ = "Copyright © 2013-2018 Caleb P. Burns"
__copyright__ = "Copyright © 2013-2020 Caleb P. Burns"
__created__ = "2013-10-12"
__credits__ = [
"dahlia <https://github.com/dahlia>",
Expand All @@ -46,13 +46,14 @@
"mroutis <https://github.com/mroutis>",
"jdufresne <https://github.com/jdufresne>",
"groodt <https://github.com/groodt>",
"ftrofin <https://github.com/ftrofin>",
]
__email__ = "cpburnz@gmail.com"
__license__ = "MPL 2.0"
__project__ = "pathspec"
__status__ = "Development"
__updated__ = "2019-12-27"
__version__ = "0.7.0"
__updated__ = "2020-01-28"
__version__ = "0.8.0.dev1"

from .pathspec import PathSpec
from .pattern import Pattern, RegexPattern
Expand Down
4 changes: 2 additions & 2 deletions pathspec/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,8 @@ def _iter_tree_next(root_full, dir_rel, memo, on_error, follow_links):
for file_rel in _iter_tree_next(root_full, node_rel, memo, on_error, follow_links):
yield file_rel

elif stat.S_ISREG(node_stat.st_mode):
# Child node is a file, yield it.
elif stat.S_ISREG(node_stat.st_mode) or is_link:
# Child node is a file or unfollowed link, yield it.
yield node_rel

# NOTE: Make sure to remove the canonical (real) path of the directory
Expand Down

0 comments on commit 2b35f31

Please sign in to comment.