feat: add more aliases
This commit is contained in:
2 files changed
+12
-10
No files matched your search
@@ -51,12 +51,13 @@ mise use -g cargo:ldr
|
|||||||
|
|
||||||
### Command aliases
|
### Command aliases
|
||||||
|
|
||||||
- `add` can also be used as `prepend`
|
- `add` can also be used as `a` or `prepend`
|
||||||
- `ls` can also be used as `list`
|
- `ls` can also be used as `l` or `list`
|
||||||
- `up` can also be used as `prioritize`
|
- `up` can also be used as `u` or `prioritize`
|
||||||
- `do` can also be used as `done`, `finish`, or `check`
|
- `do` can also be used as `d`, `done`, `finish`, or `check`
|
||||||
- `rm` can also be used as `remove`, `delete`, `destroy`, or `forget`
|
- `rm` can also be used as `remove`, `delete`, `destroy`, or `forget`
|
||||||
- `scan` can also be used as `review`
|
- `scan` can also be used as `s`, `r`, or `review`
|
||||||
|
- `edit` can also be used as `e`
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
|
|||||||
+6
-5
@@ -28,13 +28,13 @@ struct Cli {
|
|||||||
#[derive(Subcommand)]
|
#[derive(Subcommand)]
|
||||||
enum Commands {
|
enum Commands {
|
||||||
/// Add a new item at the top
|
/// Add a new item at the top
|
||||||
#[command(alias = "prepend")]
|
#[command(aliases = ["a", "prepend"])]
|
||||||
Add {
|
Add {
|
||||||
/// The text to add (e.g., "Read: Book XYZ")
|
/// The text to add (e.g., "Read: Book XYZ")
|
||||||
text: String,
|
text: String,
|
||||||
},
|
},
|
||||||
/// List the top N items (default 5)
|
/// List the top N items (default 5)
|
||||||
#[command(alias = "list")]
|
#[command(aliases = ["l", "list"])]
|
||||||
Ls {
|
Ls {
|
||||||
#[arg(short = 'n', long = "num", default_value_t = 5)]
|
#[arg(short = 'n', long = "num", default_value_t = 5)]
|
||||||
num: usize,
|
num: usize,
|
||||||
@@ -45,13 +45,13 @@ enum Commands {
|
|||||||
filter: Option<String>,
|
filter: Option<String>,
|
||||||
},
|
},
|
||||||
/// Raise the priority of items (move toward top)
|
/// Raise the priority of items (move toward top)
|
||||||
#[command(alias = "prioritize")]
|
#[command(aliases = ["u", "prioritize"])]
|
||||||
Up {
|
Up {
|
||||||
/// Item numbers to prioritize (from "ldr ls")
|
/// Item numbers to prioritize (from "ldr ls")
|
||||||
numbers: Vec<usize>,
|
numbers: Vec<usize>,
|
||||||
},
|
},
|
||||||
/// Archive completed items
|
/// Archive completed items
|
||||||
#[command(aliases = ["done", "finish", "check"])]
|
#[command(aliases = ["d", "done", "finish", "check"])]
|
||||||
Do {
|
Do {
|
||||||
/// Item numbers to archive (from "ldr ls")
|
/// Item numbers to archive (from "ldr ls")
|
||||||
numbers: Vec<usize>,
|
numbers: Vec<usize>,
|
||||||
@@ -63,9 +63,10 @@ enum Commands {
|
|||||||
numbers: Vec<usize>,
|
numbers: Vec<usize>,
|
||||||
},
|
},
|
||||||
/// Scan and review items interactively, from top to bottom
|
/// Scan and review items interactively, from top to bottom
|
||||||
#[command(alias = "review")]
|
#[command(aliases = ["s", "r", "review"])]
|
||||||
Scan,
|
Scan,
|
||||||
/// Edit items in your $EDITOR
|
/// Edit items in your $EDITOR
|
||||||
|
#[command(alias = "e")]
|
||||||
Edit,
|
Edit,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user