File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed
Sources/SmithyCodegenCore Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change 66//
77
88import struct Foundation. Data
9+ import class Foundation. FileManager
910import class Foundation. JSONDecoder
1011import struct Foundation. URL
1112
@@ -26,7 +27,15 @@ public struct CodeGenerator {
2627 let modelData = try Data ( contentsOf: modelFileURL)
2728 let astModel = try JSONDecoder ( ) . decode ( ASTModel . self, from: modelData)
2829
29- // In the future, AST will be used to create a Model
30- // Model will be used to generate code
30+ // In the future, AST will be used to create a Model.
31+ // Model will be used to generate code.
32+
33+ // This code simply writes an empty schemas file, since it is expected to exist after the
34+ // code generator plugin runs.
35+ //
36+ // Actual code generation will be implemented here later.
37+ if let schemasFileURL {
38+ FileManager . default. createFile ( atPath: schemasFileURL. path, contents: Data ( ) )
39+ }
3140 }
3241}
You can’t perform that action at this time.
0 commit comments