Skip to content

Commit

Permalink
Comments and screenshot.
Browse files Browse the repository at this point in the history
  • Loading branch information
Magicolo committed Mar 30, 2024
1 parent 6ed4f5d commit 8ee92cd
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .devcontainer
Submodule .devcontainer updated 1 files
+1 −1 Dockerfile
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "scalp"
version = "0.4.0"
version = "0.4.1"
authors = ["Magicolo <magicololand@gmail.com>"]
edition = "2021"
readme = "README.md"
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
*Less magic, more control, same speed.* </em>
</p>

<div>
<a href="https://github.com/Magicolo/scalp"> <img src="https://github.com/Magicolo/scalp/resources/screen.png"> </a>
</div>

<div align="right">
<a href="https://github.com/Magicolo/scalp/actions/workflows/test.yml"> <img src="https://github.com/Magicolo/scalp/actions/workflows/test.yml/badge.svg"> </a>
<a href="https://crates.io/crates/scalp"> <img src="https://img.shields.io/crates/v/scalp.svg"> </a>
Expand Down
1 change: 1 addition & 0 deletions examples/cargo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@ use scalp::*;
pub struct Cargo {}

fn main() -> Result<(), Error> {
// TODO...
Ok(())
}
1 change: 1 addition & 0 deletions examples/git.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@ use scalp::*;
pub struct Git {}

fn main() -> Result<(), Error> {
// TODO...
Ok(())
}
8 changes: 5 additions & 3 deletions examples/scalp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ pub enum Command {
#[derive(Debug)]
pub struct Root {
pub commands: Vec<Command>,
pub kroule: String,
pub count: usize,
pub name: String,
}

fn main() -> Result<(), Box<dyn error::Error>> {
Expand Down Expand Up @@ -49,10 +50,11 @@ fn main() -> Result<(), Box<dyn error::Error>> {
.group(|group| {
group
.name("Options:")
.option(|option| option.name("kroule").require())
.option(|option| option.position().require())
.option(|option| option.name("name").require())
.options(Options::all(true, true))
})
.map(|(commands, (kroule,))| Root { commands, kroule })
.map(|(commands, (count, name))| Root { commands, count, name })
.note("A note.")
.build()?
// .parse_with(["fett", "j", "--help"], [("", "")])?;
Expand Down
Binary file added resources/screen.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 8ee92cd

Please sign in to comment.