refactor: update remote tag fetching behaviour so it uses api instead of shallow clone

This commit is contained in:
Jonathan Teran Carballo
2026-09-21 09:15:48 -03:00
parent eabef5eb33
commit 22ba8f5e5f
7 changed files with 89 additions and 14 deletions
+5
View File
@@ -74,6 +74,11 @@ class GiteaRemoteAPI(RemoteAPI):
for c in reversed(items)
]
def list_tags(self, suffix: str = "") -> list[str]:
tags = self.get_all_pages(self.get_endpoint("/tags"), 50, size_param="limit")
return [t["name"] for t in tags]
def get_endpoint(self, resource: str) -> str:
return f"{self.base_url}/api/v1/repos/{self.repository}{resource}"