File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -175,12 +175,14 @@ function terraform_docs {
175
175
176
176
if [[ $output_file ]]; then
177
177
# Extract filename from `output.file` line
178
- text_file =$( echo " $output_file " | awk -F' :' ' {print $2}' | tr -d ' [:space:]"' | tr -d " '" )
178
+ output_file =$( echo " $output_file " | awk -F' :' ' {print $2}' | tr -d ' [:space:]"' | tr -d " '" )
179
179
180
- if [[ $use_path_to_file ]]; then
181
- common::colorify " yellow" " NOTE: You set both '--hook-config=--path-to-file=' and 'output.file' in '$config_file '"
180
+ if [[ $use_path_to_file == true && " $output_file " != " $text_file " ]]; then
181
+ common::colorify " yellow" " NOTE: You set both '--hook-config=--path-to-file=$text_file ' and 'output.file: $output_file ' in '$config_file '"
182
182
common::colorify " yellow" " 'output.file' from '$config_file ' will be used."
183
183
fi
184
+
185
+ text_file=$output_file
184
186
fi
185
187
186
188
# Suppress terraform_docs color
You can’t perform that action at this time.
0 commit comments