stash: use more granular STASH_CLIPBOARD_STATE

Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: I6a6a6964d59d2ce974ba482aee9b1c8f20cdb44e
This commit is contained in:
raf 2025-08-12 15:33:53 +03:00
commit 0e4f4018ab
Signed by: NotAShelf
GPG key ID: 29D95B64378DB4BF
2 changed files with 4 additions and 2 deletions

View file

@ -288,7 +288,9 @@ pub fn u64_to_ivec(v: u64) -> IVec {
}
pub fn ivec_to_u64(v: &IVec) -> u64 {
let arr: [u8; 8] = if let Ok(arr) = v.as_ref().try_into() { arr } else {
let arr: [u8; 8] = if let Ok(arr) = v.as_ref().try_into() {
arr
} else {
error!("Failed to convert IVec to u64: invalid length");
return 0;
};

View file

@ -92,7 +92,7 @@ fn main() {
match cli.command {
Some(Command::Store) => {
log::info!("Executing: Store");
let state = env::var("CLIPBOARD_STATE").ok();
let state = env::var("STASH_CLIPBOARD_STATE").ok();
db.store(io::stdin(), cli.max_dedupe_search, cli.max_items, state);
}
Some(Command::List) => {