Now takes non-specified args as a file

This commit is contained in:
Nathaniel Landau
2015-04-10 14:34:18 -04:00
parent c8f0e6f882
commit 61e6dda32a

View File

@@ -137,6 +137,10 @@ function outputDir() {
} }
function identifyUserFile() { function identifyUserFile() {
if [[ -n "${args}" ]]; then
userFile="${args}"
fi
if [[ -n "${userFile}" ]]; then if [[ -n "${userFile}" ]]; then
#test -f "${f}" # Ensure that what we've found is a file #test -f "${f}" # Ensure that what we've found is a file
extension="${userFile##*.}" # Grab file extension of input file extension="${userFile##*.}" # Grab file extension of input file
@@ -153,9 +157,8 @@ function userFormat() {
# Reads user input for format (-o, --output) # Reads user input for format (-o, --output)
# Override defaults with CLI # Override defaults with CLI
if [ -n "$userOutput" ]; then if [ -n "$userOutput" ]; then
outputFormat="${userOutput,,}" outputFormat="${userOutput,,}" && verbose "outputFormat=${outputFormat}"
fi fi
verbose "outputFormat=${outputFormat}"
} }
function doConvert() { function doConvert() {