'clear' command

This commit is contained in:
Nox Sluijtman 2025-06-19 17:21:13 +02:00
parent cbf90ce5f0
commit 64c6487560
Signed by: Egg
SSH key fingerprint: SHA256:2sG9X3C7Xvq2svGumz1/k7cm8l4G9+qAtAeugqB4J9M
3 changed files with 8 additions and 2 deletions

2
Cargo.lock generated
View file

@ -249,7 +249,7 @@ dependencies = [
[[package]]
name = "noise"
version = "0.1.2"
version = "0.1.3"
dependencies = [
"clap",
"libnotify",

View file

@ -1,6 +1,6 @@
[package]
name = "noise"
version = "0.1.2"
version = "0.1.3"
edition = "2024"
[dependencies]

View file

@ -39,6 +39,8 @@ enum Commands {
Update {},
/// Return currently playing song
Current {},
/// Clear current queueueu
Clear {},
/// Query database
Search {
///Search query
@ -156,6 +158,10 @@ fn main() {
println!("{status}");
}
Commands::Clear {} => {
conn.clear().unwrap();
}
Commands::Search {
query,
max,