Skip to content

Commit

Permalink
Merge pull request #178 from boltops-tools/expander-backend
Browse files Browse the repository at this point in the history
fix no backend.tf src file case
  • Loading branch information
tongueroo authored Dec 29, 2021
2 parents ddf0790 + ad9f437 commit b801b18
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/terraspace/compiler/expander/backend.rb
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ def initialize(mod)
COMMENT = /^\s+#/
# Works for both backend.rb DSL and backend.tf ERB
def detect
return nil unless src_path # no backend file. returning nil means a local backend
lines = IO.readlines(src_path)
backend_line = lines.find { |l| l.include?("backend") && l !~ COMMENT }
md = backend_line.match(/['"](.*)['"]/)
Expand Down

0 comments on commit b801b18

Please # to comment.