File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ function tfenv-version-name() {
10
10
&& log ' debug' " TFENV_VERSION_FILE retrieved from tfenv-version-file: ${TFENV_VERSION_FILE} " \
11
11
|| log ' error' ' Failed to retrieve TFENV_VERSION_FILE from tfenv-version-file' ;
12
12
13
- TFENV_VERSION=" $( cat " ${TFENV_VERSION_FILE} " || true) " \
13
+ TFENV_VERSION=" $( cat " ${TFENV_VERSION_FILE} " || true | tr -d ' \r ' ) " \
14
14
&& log ' debug' " TFENV_VERSION specified in TFENV_VERSION_FILE: ${TFENV_VERSION} " ;
15
15
16
16
TFENV_VERSION_SOURCE=" ${TFENV_VERSION_FILE} " ;
Original file line number Diff line number Diff line change @@ -77,12 +77,12 @@ if [ -z "${arg}" -a -z "${TFENV_TERRAFORM_VERSION:-""}" ]; then
77
77
78
78
if [ " ${version_file} " != " ${TFENV_CONFIG_DIR} /version" ]; then
79
79
log ' debug' " Version File (${version_file} ) is not the default \$ {TFENV_CONFIG_DIR}/version (${TFENV_CONFIG_DIR} /version)" ;
80
- version_requested=" $( cat " ${version_file} " ) " \
80
+ version_requested=" $( cat " ${version_file} " | tr -d ' \r ' ) " \
81
81
|| log ' error' " Failed to open ${version_file} " ;
82
82
83
83
elif [ -f " ${version_file} " ]; then
84
84
log ' debug' " Version File is the default \$ {TFENV_CONFIG_DIR}/version (${TFENV_CONFIG_DIR} /version)" ;
85
- version_requested=" $( cat " ${version_file} " ) " \
85
+ version_requested=" $( cat " ${version_file} " | tr -d ' \r ' ) " \
86
86
|| log ' error' " Failed to open ${version_file} " ;
87
87
88
88
# Absolute fallback
You can’t perform that action at this time.
0 commit comments