mirror of
https://git.suyu.dev/suyu/yuzu-games-parser
synced 2024-11-21 14:29:03 -07:00
Add build date
This commit is contained in:
parent
16425d4301
commit
991c8d737c
3 changed files with 14 additions and 11 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -2,3 +2,4 @@
|
|||
/Cargo.lock
|
||||
src/US.en.json
|
||||
.idea
|
||||
.DS_Store
|
|
@ -40,7 +40,7 @@ fn main() -> anyhow::Result<()> {
|
|||
println!("{}", serde_json::to_string_pretty(&serialize::Game {
|
||||
name: result.title.clone(),
|
||||
description: eshop.get(&eshop_id).unwrap().get("description").unwrap().as_str().unwrap().to_string(),
|
||||
titleId: title_id,
|
||||
title_id,
|
||||
img: eshop.get(&eshop_id).unwrap().get("iconUrl").unwrap().as_str().unwrap().to_string(),
|
||||
tests: result.testcases.iter().map(|x| serialize::testcase_to_test(x)).collect(),
|
||||
}).unwrap());
|
||||
|
|
|
@ -5,21 +5,22 @@ use crate::{OS, TestCase};
|
|||
pub struct Game {
|
||||
pub(crate) name: String,
|
||||
pub(crate) description: String,
|
||||
pub(crate) titleId: String,
|
||||
pub(crate) title_id: String,
|
||||
pub(crate) img: String,
|
||||
pub(crate) tests: Vec<Test>,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize)]
|
||||
pub struct Test {
|
||||
pub(crate) tester: Option<String>,
|
||||
pub(crate) rating: i8,
|
||||
pub(crate) details: Option<String>,
|
||||
pub(crate) cpu: String,
|
||||
pub(crate) gpu: String,
|
||||
pub(crate) version: String,
|
||||
pub(crate) os: String,
|
||||
pub(crate) from_yuzu: bool,
|
||||
pub tester: Option<String>,
|
||||
pub rating: i8,
|
||||
pub details: Option<String>,
|
||||
pub test_date: String,
|
||||
pub cpu: String,
|
||||
pub gpu: String,
|
||||
pub version: String,
|
||||
pub os: String,
|
||||
pub from_yuzu: bool,
|
||||
}
|
||||
|
||||
pub fn testcase_to_test(case: &TestCase) -> Test {
|
||||
|
@ -35,6 +36,7 @@ pub fn testcase_to_test(case: &TestCase) -> Test {
|
|||
_ => unreachable!()
|
||||
},
|
||||
details: None,
|
||||
test_date: case.date.clone(),
|
||||
cpu: case.cpu.clone(),
|
||||
gpu: case.gpu.clone(),
|
||||
version: case.version.clone(),
|
||||
|
|
Loading…
Reference in a new issue