deleteRepositoryTag method
Implementation
Future<void> deleteRepositoryTag({required String projectId, required String repositoryId, required String tag}) async {
final encodedProjectId = Uri.encodeComponent(projectId);
final encodedRepositoryId = Uri.encodeComponent(repositoryId);
final encodedTag = Uri.encodeComponent(tag);
final uri = Uri.parse('$baseUrl/accounts/projects/$encodedProjectId/repositories/$encodedRepositoryId/tags/$encodedTag');
final response = await httpClient.delete(uri);
if (response.statusCode == 404) {
throw NotFoundException('Repository tag not found: $tag');
}
if (response.statusCode >= 400) {
throw MeshagentException(
'Failed to delete repository tag. '
'Status code: ${response.statusCode}, body: ${response.body}',
);
}
}