v2.0.1 - fixed bug where variable was malformed.

This commit is contained in:
Nathaniel Landau
2016-01-09 22:04:23 -05:00
parent 779741dcdf
commit bc02ca013f

View File

@@ -3,7 +3,7 @@
# ##################################################
# My Generic BASH script template
#
version="2.0.0" # Sets version variable for this script
version="2.0.1" # Sets version variable for this script
#
scriptTemplateVersion="1.5.0" # Version of scriptTemplate.sh that this script is based on
#
@@ -15,11 +15,12 @@ scriptTemplateVersion="1.5.0" # Version of scriptTemplate.sh that this script is
# * 2015-05-26 - v1.1.1 - Fixed log level on downsize720
# * 2015-08-30 - v1.2.0 - Support for recursive directory conversions
# * 2016-01-03 - v1.2.1 - Fixed XLD audio conversion which had been broken
# * 2016-01-15 - v2.0.0 - Major refactoring of code.
# * 2016-01-05 - v2.0.0 - Major refactoring of code.
# - Better JSON parsing via JQ
# - MIME type discovery based on file metadata (rather than user input)
# - Better error handling
# - Better renaming of existing files
# * 2016-01-09 - v2.0.1 - Fixed bug on in video preset section where 'videoPreset' was malformed
#
#
# TODO
@@ -152,7 +153,7 @@ function mainScript() {
# Figure out what to do if a user doesn't specify any files or input types
if [ ${#filesToConvert[@]} -eq 0 ]; then
notice "We couldn't find any files to act on."
notice "You didn't specify a specific file."
seek_confirmation "Do you want to convert all VIDEO files?"
if is_confirmed; then
for fileType in "${videoTypes[@]}"; do
@@ -350,7 +351,7 @@ function mainScript() {
videoPreset="1080p" && verbose "Input video has preset: 1080p"
fi
if [[ "${videoWidth}" == "1280" && "${videoHeight}" == "720" ]] || [[ "${videoWidth}" == "1280" && "$videoHeight" == "544" ]]; then
{videoPreset}="720p" && verbose "Input video has preset: 720p"
videoPreset="720p" && verbose "Input video has preset: 720p"
fi
if [[ "${videoWidth}" == "720" && "${videoHeight}" == "576" ]]; then
videoPreset="DVPAL" && verbose "Input video has preset: DVPAL"