Skip to content

Commit 8d26a7c

Browse files
committed
Always record the git branch command as success
This is causing the build to be marked as FAILED when the repository has no branches. Closes #3644
1 parent 09f8282 commit 8d26a7c

File tree

1 file changed

+2
-2
lines changed
  • readthedocs/vcs_support/backends

1 file changed

+2
-2
lines changed

readthedocs/vcs_support/backends/git.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,8 @@ def parse_tags(self, data):
122122
@property
123123
def branches(self):
124124
# Only show remote branches
125-
retcode, stdout, _ = self.run('git', 'branch', '-r')
126-
# error (or no tags found)
125+
retcode, stdout, _ = self.run('git', 'branch', '-r', record_as_success=True)
126+
# error (or no branches found)
127127
if retcode != 0:
128128
return []
129129
return self.parse_branches(stdout)

0 commit comments

Comments
 (0)