Skip to content

Commit

Permalink
Update to use correct parsing method to handle comments in smithy-bui…
Browse files Browse the repository at this point in the history
…ld.json (#110)
  • Loading branch information
hpmellema authored Dec 20, 2023
1 parent 776d4d1 commit ee7c25a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/base-plugin/smithy-build-task/smithy-build.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
{
// A comment.
"version": "1.0"
}
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ private static Optional<String> parseOutputDirFromBuildConfig(Path buildConfigPa
if (!Files.exists(buildConfigPath)) {
return Optional.empty();
}
return Node.parse(IoUtils.readUtf8File(buildConfigPath))
return Node.parseJsonWithComments(IoUtils.readUtf8File(buildConfigPath))
.expectObjectNode()
.getMember(OUTPUT_DIRECTORY)
.map(Node::expectStringNode)
Expand Down

0 comments on commit ee7c25a

Please sign in to comment.