Correct variables name in flac_to_mp3 script: error if the variable
content had white spaces.
This commit is contained in:
parent
596fdf9f85
commit
63bc985178
|
@ -8,7 +8,7 @@ BITRATE="128k"
|
||||||
LOG_LEVEL="error"
|
LOG_LEVEL="error"
|
||||||
|
|
||||||
## If it's an album
|
## If it's an album
|
||||||
if [ -d ${ALBUM_NAME} ]; then
|
if [ -d "${ALBUM_NAME}" ]; then
|
||||||
printf 'Convert %s to %s\n' "${ALBUM_NAME}" "${NEW_ALBUM_NAME}"
|
printf 'Convert %s to %s\n' "${ALBUM_NAME}" "${NEW_ALBUM_NAME}"
|
||||||
|
|
||||||
## Create the new directory
|
## Create the new directory
|
||||||
|
@ -28,7 +28,7 @@ if [ -d ${ALBUM_NAME} ]; then
|
||||||
|
|
||||||
else
|
else
|
||||||
FILE="${ALBUM_NAME}"
|
FILE="${ALBUM_NAME}"
|
||||||
if [ -f ${FILE} ]; then
|
if [ -f "${FILE}" ]; then
|
||||||
printf 'Convert %s to %s\n' "${FILE}" "${NEW_FORMAT}"
|
printf 'Convert %s to %s\n' "${FILE}" "${NEW_FORMAT}"
|
||||||
avconv -v "${LOG_LEVEL}" -i "${FILE}" -b "${BITRATE}" "${FILE%${OLD_FORMAT}}${NEW_FORMAT}"
|
avconv -v "${LOG_LEVEL}" -i "${FILE}" -b "${BITRATE}" "${FILE%${OLD_FORMAT}}${NEW_FORMAT}"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue