mirror of
https://github.com/NotAShelf/stash.git
synced 2026-05-09 00:45:32 +00:00
treewide: make logging format more consistent; make clipboard persistence opt-in
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I9092f93c29fcbe99c90483875f4acd0c6a6a6964
This commit is contained in:
parent
9702e67599
commit
da9bf5ea3e
11 changed files with 44 additions and 32 deletions
|
|
@ -160,6 +160,10 @@ enum Command {
|
|||
/// MIME type preference for clipboard reading.
|
||||
#[arg(short = 't', long, default_value = "any")]
|
||||
mime_type: String,
|
||||
|
||||
/// Persist clipboard contents after the source application closes.
|
||||
#[arg(long)]
|
||||
persist: bool,
|
||||
},
|
||||
}
|
||||
|
||||
|
|
@ -201,7 +205,7 @@ fn confirm(prompt: &str) -> bool {
|
|||
.with_default(false)
|
||||
.prompt()
|
||||
.unwrap_or_else(|e| {
|
||||
log::error!("Confirmation prompt failed: {e}");
|
||||
log::error!("confirmation prompt failed: {e}");
|
||||
false
|
||||
})
|
||||
}
|
||||
|
|
@ -477,6 +481,7 @@ fn main() -> eyre::Result<()> {
|
|||
Some(Command::Watch {
|
||||
expire_after,
|
||||
mime_type,
|
||||
persist,
|
||||
}) => {
|
||||
db.watch(
|
||||
cli.max_dedupe_search,
|
||||
|
|
@ -489,6 +494,7 @@ fn main() -> eyre::Result<()> {
|
|||
&mime_type,
|
||||
cli.min_size,
|
||||
cli.max_size,
|
||||
persist,
|
||||
)
|
||||
.await;
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue