ci: run fmt, clippy and tests on the Gitea runner #18

Merged
andreban merged 2 commits from ci/gitea-actions into main 2026-10-26 20:42:05 +00:00
4 changed files with 72 additions and 66 deletions
Showing only changes of commit c911fc382e - Show all commits

View File

@@ -1,5 +1,5 @@
use console::style;
use dialoguer::{theme::ColorfulTheme, Input};
use dialoguer::{Input, theme::ColorfulTheme};
use gemini_rs::prelude::*;
use std::time::Duration;

View File

@@ -19,10 +19,12 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
.add_text_part("Answer as if you were Yoda")
.build();
let user_prompt = vec![Content::builder()
let user_prompt = vec![
Content::builder()
.role(Role::User)
.add_text_part("What is the airspeed of an unladen swallow?")
.build()];
.build(),
];
let request = GenerateContentRequest::builder()
.contents(user_prompt)

View File

@@ -15,10 +15,12 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
location_id,
);
let prompt = vec![Content::builder()
let prompt = vec![
Content::builder()
.role(Role::User)
.add_text_part("Tell me the story of the genesis of the universe as a bedtime story.")
.build()];
.build(),
];
let request = GenerateContentRequest::builder().contents(prompt).build();

View File

@@ -14,10 +14,12 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
location_id,
);
let prompt = vec![Content::builder()
let prompt = vec![
Content::builder()
.role(Role::User)
.add_text_part("What is the airspeed of an unladen swallow?")
.build()];
.build(),
];
let request = GenerateContentRequest::builder().contents(prompt).build();
let response = gemini.generate_content(&request, "gemini-pro").await?;