Switch to vscode + fetch bot_name with token
ci/woodpecker/push/tests Pipeline failed

This commit is contained in:
qpismont committed 2026-06-30 20:44:25 +00:00
1 parent 7f24d7657c
commit 743b6b33c9
10 files changed
+75 -154

No files matched your search

+16
View File
@@ -29,6 +29,21 @@ impl GiteaAPI {
})
}
#[instrument(skip(self))]
pub async fn get_authorized_user(&self) -> anyhow::Result<User> {
let url = format!("{}/api/v1/user", self.base_url);
let res = self.client.get(url).send().await?;
if !res.status().is_success() {
return Err(anyhow::anyhow!(
"Failed to get authorized user: {}",
res.status()
));
}
res.json::<User>().await.map_err(anyhow::Error::from)
}
#[instrument(skip(self))]
pub async fn comment(
&self,
@@ -192,6 +207,7 @@ pub struct Comment {
#[derive(Deserialize, Debug)]
pub struct User {
pub id: u64,
pub login: String,
}
#[derive(Deserialize, Debug)]