Cleanup
This commit is contained in:
parent
a74c3d2a3d
commit
5556ea70df
3 changed files with 26 additions and 14 deletions
15
src/main.rs
15
src/main.rs
|
@ -33,7 +33,7 @@ fn main() {
|
|||
|
||||
if let Some(cmd) = &cli.command {
|
||||
match cmd {
|
||||
Commands::Play { track } => conn.noise_play(*track),
|
||||
Commands::Play { track } => Noise::play(&mut conn, *track),
|
||||
Commands::Stop => conn.stop().unwrap(),
|
||||
Commands::Toggle => conn.toggle(),
|
||||
Commands::Next => conn.next().unwrap(),
|
||||
|
@ -41,9 +41,9 @@ fn main() {
|
|||
Commands::List { file } => conn.list_queue(*file, cli.verbose),
|
||||
Commands::Current => (),
|
||||
Commands::Clear => conn.clear().unwrap(),
|
||||
Commands::Search { query, max } => conn.noise_search(query, *max),
|
||||
Commands::Find { query, max, append } => conn.noise_find(query, *max, *append),
|
||||
Commands::Crossfade { seconds } => conn.noise_crossfade(*seconds),
|
||||
Commands::Search { query, max } => Noise::search(&mut conn, query, *max),
|
||||
Commands::Find { query, max, append } => Noise::find(&mut conn, query, *max, *append),
|
||||
Commands::Crossfade { seconds } => Noise::crossfade(&mut conn, *seconds),
|
||||
Commands::Shuffle => conn.shuf(),
|
||||
Commands::Repeat => conn.toggle_repeat(),
|
||||
Commands::Random => conn.toggle_random(),
|
||||
|
@ -65,5 +65,12 @@ fn main() {
|
|||
return;
|
||||
}
|
||||
}
|
||||
let things: Vec<String> = conn
|
||||
.queue()
|
||||
.unwrap()
|
||||
.iter()
|
||||
.map(|x| x.place.unwrap().pos.to_string())
|
||||
.collect();
|
||||
println!("{things:?}");
|
||||
println!("{}", conn.get_status(cli.verbose));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue