Mountain/Command/SourceControlManagement/
GetSCMCommitHistory.rs1#![allow(non_snake_case)]
2
3use std::sync::Arc;
12
13use serde_json::{Value, json};
14use tauri::{State, command};
15
16use crate::{ApplicationState::State::ApplicationState::ApplicationState, dev_log};
17
18#[command]
19pub async fn GetSCMCommitHistory(
20 _State:State<'_, Arc<ApplicationState>>,
21
22 MaxCount:Option<usize>,
23) -> Result<Value, String> {
24 dev_log!("commands", "getting commit history, max count: {:?}", MaxCount);
25
26 let MaxCommits = MaxCount.unwrap_or(50);
27
28 Ok(json!({
29 "commits": Vec::<Value>::new(),
30 "maxCount": MaxCommits,
31 }))
32}