Show More
@@ -154,9 +154,8 def get_repos(path, recursive=False): | |||||
154 | from vcs.utils.helpers import get_scm |
|
154 | from vcs.utils.helpers import get_scm | |
155 | from vcs.exceptions import VCSError |
|
155 | from vcs.exceptions import VCSError | |
156 |
|
156 | |||
157 | if path.endswith(os.sep): |
|
157 | # remove ending slash for better results | |
158 | #remove ending slash for better results |
|
158 | path = path.rstrip('/') | |
159 | path = path[:-1] |
|
|||
160 |
|
159 | |||
161 | def _get_repos(p): |
|
160 | def _get_repos(p): | |
162 | if not os.access(p, os.W_OK): |
|
161 | if not os.access(p, os.W_OK): | |
@@ -167,7 +166,7 def get_repos(path, recursive=False): | |||||
167 | cur_path = os.path.join(p, dirpath) |
|
166 | cur_path = os.path.join(p, dirpath) | |
168 | try: |
|
167 | try: | |
169 | scm_info = get_scm(cur_path) |
|
168 | scm_info = get_scm(cur_path) | |
170 | yield scm_info[1].split(path)[-1].lstrip(os.sep), scm_info |
|
169 | yield scm_info[1].split(path, 1)[-1].lstrip(os.sep), scm_info | |
171 | except VCSError: |
|
170 | except VCSError: | |
172 | if not recursive: |
|
171 | if not recursive: | |
173 | continue |
|
172 | continue |
General Comments 0
You need to be logged in to leave comments.
Login now