Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 3f4b410

Browse filesBrowse files
committed
Switching the urls property to use git remote show instead of git remote get-url
`get-url` is a new API that is not widely available yet (introduced in git 2.7.0), and provokes failure on travis. Signed-off-by: Guyzmo <guyzmo+github@m0g.net>
1 parent b366d3f commit 3f4b410
Copy full SHA for 3f4b410

1 file changed

+4-4Lines changed: 4 additions & 4 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎git/remote.py‎

Copy file name to clipboardExpand all lines: git/remote.py
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -477,10 +477,10 @@ def delete_url(self, url, **kwargs):
477477
def urls(self):
478478
""":return: Iterator yielding all configured URL targets on a remote
479479
as strings"""
480-
scmd = 'get-url'
481-
kwargs = {'insert_kwargs_after': scmd}
482-
for url in self.repo.git.remote(scmd, self.name, all=True, **kwargs).split('\n'):
483-
yield url
480+
remote_details = self.repo.git.remote("show", self.name)
481+
for line in remote_details.split('\n'):
482+
if ' Push URL:' in line:
483+
yield line.split(': ')[-1]
484484

485485
@property
486486
def refs(self):

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.