fix more syntax errors

This commit is contained in:
lelgenio 2020-10-05 19:25:31 -03:00
parent 592011738b
commit 65fcf5ddee
1 changed files with 5 additions and 5 deletions

View File

@ -5,7 +5,7 @@ menu=wdmenu
search(){
music=$(mpc playlist --format '%artist% : %title%' | sed '/^ : $/d' | $menu)
if [ "$music" == "" ]
if [ "$music" = "" ]
then
exit 1
fi
@ -26,8 +26,8 @@ delete(){
print $2
}' $config_root/mpd/mpd.conf)
current="$music_root"/"$(mpc current -f %file%)"
answer=$(echo -e "nothing\n$current" | $menu -p"delete?" )
if [ "$answer" == "$current" ]
answer=$(echo "nothing\n$current" | $menu -p"delete?" )
if [ "$answer" = "$current" ]
then
trash "$answer"
mpc --quiet next
@ -41,10 +41,10 @@ usage(){
echo " $0 delete -- prompts to delete the current song"
}
if [ "$1" == "delete" ]
if [ "$1" = "delete" ]
then
delete
elif [ "$1" == "search" ]
elif [ "$1" = "search" ]
then
search
else