Skip to content

Commit

Permalink
Merge pull request #293 from terrateamio/main
Browse files Browse the repository at this point in the history
Release v1
  • Loading branch information
orbitz authored Jul 19, 2024
2 parents f48c65c + 00d883b commit 40c6bd8
Showing 1 changed file with 0 additions and 16 deletions.
16 changes: 0 additions & 16 deletions terrat_runner/infracost.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,22 +18,6 @@ def convert_cost(cost):


def create_infracost_yml(outname, dirspaces):
# We want to configure infracost with the most minimal configuration, so we
# find the set of base directories that we'll run in (with a check for if
# "." is in there) and create a new set of dirspaces just for those, and
# then build the config.
by_workspace = {}
for ds in dirspaces:
by_workspace.setdefault(ds['workspace'], []).append(ds)

dirspaces = []
for ws, dspaces in by_workspace.items():
ds = set([d['path'].split('/')[0] for d in dspaces])
if '.' in ds:
dirspaces.append({'path': '.', 'workspace': ws})
else:
dirspaces.extend([{'path': d, 'workspace': ws} for d in ds])

config = {
'version': '0.1',
'projects': [
Expand Down

0 comments on commit 40c6bd8

Please sign in to comment.