implement transcode switcher

This commit is contained in:
localhost_frssoft 2022-07-18 02:10:58 +03:00
parent bffd430fc8
commit e9bf201065
1 changed files with 11 additions and 0 deletions

View File

@ -405,6 +405,17 @@ funkwhale_pseudofs_load()
done
}
funkwhale_pseudofs_transcode_switch()
{
echo "Transcode to"
transcode_ch=$(echo "none\nogg\nmp3" | fzy)
if [ "$transcode_ch" = 'none' ]; then
find "fwfs_$instance" -type f -exec sed -i 's/to=.*/to=/' {} +
else
find "fwfs_$instance" -type f -exec sed -i "s/to=.*/to=$transcode_ch/" {} +
fi
}
trackspls='Tracks'
albumsmenu='Albums'
artistmenu='Artists'