diff --git a/package.json b/package.json index 9e04450..1977237 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "infracost", "displayName": "Infracost", "description": "Cloud cost estimates for Terraform in your editor", - "version": "0.2.26", + "version": "0.2.27", "publisher": "Infracost", "license": "Apache-2.0", "icon": "infracost-logo.png", @@ -141,4 +141,4 @@ "handlebars": "^4.7.7", "js-yaml": "^4.1.0" } -} +} \ No newline at end of file diff --git a/src/workspace.ts b/src/workspace.ts index 26441dc..be0f1f3 100644 --- a/src/workspace.ts +++ b/src/workspace.ts @@ -302,7 +302,7 @@ export default class Workspace { const formatted = new Project(name, projectPath, this.currency, this.blockTemplate); for (const resource of project.breakdown.resources) { for (const call of resource.metadata.calls) { - const filename = cleanFilename(call.filename); + const filename = path.resolve(cleanFilename(call.filename)); logger.debug(`adding file: ${filename} to project: ${projectPath}`); formatted.setBlock(filename, call.blockName, call.startLine).resources.push(resource);