MCPcopy Create free account
hub / github.com/apache/solr / _find_apache_remote

Method _find_apache_remote

dev-tools/scripts/validateChangelogs.py:161–170  ·  view source on GitHub ↗

Find the official Apache Solr remote (matching 'apache' and 'solr' in URL).

(self)

Source from the content-addressed store, hash-verified

159 return True
160
161 def _find_apache_remote(self) -> Optional[str]:
162 """Find the official Apache Solr remote (matching 'apache' and 'solr' in URL)."""
163 result = self.run_git(["remote", "-v"], check=False)
164 if result.returncode != 0:
165 return None
166
167 for parts in (line.split() for line in result.stdout.strip().split("\n") if line):
168 if len(parts) >= 2 and "apache" in parts[1].lower() and "solr" in parts[1].lower():
169 return parts[0]
170 return None
171
172 def _get_remote_branches(self, remote: str) -> set:
173 """Get list of available branches from remote."""

Callers 2

_git_ref_outputMethod · 0.95

Calls 3

run_gitMethod · 0.95
stripMethod · 0.80
splitMethod · 0.45

Tested by

no test coverage detected