also allow arguments

This commit is contained in:
Nox Sluijtman 2024-09-25 11:46:44 +02:00
parent decb091842
commit 2a0a46a042

View file

@ -118,16 +118,18 @@ def "main search" [--field(-f): string=any # Field to query
# Insert uri after currently playing song
def "main insert" [ --host(-H): string # mpd host
, ...uri: string # URI to insert
] {
let host = getHost $host
$in | mpc insert --host $host
$in | mpc insert --host $host ($uri | str join " ")
}
# Adds uri to the end of current que
def "main add" [ --host(-H): string # mpd host
, ...uri: string # URI to add
] {
let host = getHost $host
$in | mpc add --host $host
$in | mpc add --host $host ($uri | str join " ")
}
# Direct wrapper around 'mpc crossfade'