MCPcopy Create free account
hub / github.com/alt-art/commit / required_input

Method required_input

src/commit_message/prompt.rs:33–39  ·  view source on GitHub ↗
(&self, prompt: &str, label: &str)

Source from the content-addressed store, hash-verified

31 }
32
33 pub fn required_input(&self, prompt: &str, label: &str) -> Result<String> {
34 let input = Text::new(prompt)
35 .with_render_config(self.config)
36 .with_validator(required!(format!("{label} can't be empty").as_str()))
37 .prompt()?;
38 Ok(input)
39 }
40
41 pub fn select(&self, prompt: &str, choices: Vec<Type>) -> Result<String> {
42 let choice = Select::new(prompt, choices)

Callers 2

scope_choiceMethod · 0.80
descriptionMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected