@@ -18,7 +18,7 @@ Initial setup: Gradle (recommended)
1818
1919To generate a Java client for a service, start by creating a new Smithy Gradle project.
2020
21- The ``smithy init` `` CLI command can be used to create a new Smithy Gradle project:
21+ The ``smithy init `` CLI command can be used to create a new Smithy Gradle project:
2222
2323.. code-block :: sh
2424
@@ -43,10 +43,10 @@ and execute build plugins:
4343.. code-block :: diff
4444 :caption: build.gradle.kts
4545
46- plugins {
47- `java-library`
48- + id("software.amazon.smithy.gradle.smithy-base") version "__smithy_gradle_version__"
49- }
46+ plugins {
47+ `java-library`
48+ + id("software.amazon.smithy.gradle.smithy-base") version "__smithy_gradle_version__"
49+ }
5050
5151 Add the following dependencies to your project:
5252
@@ -84,16 +84,16 @@ your :ref:`smithy-build <smithy-build>` config:
8484.. code-block :: diff
8585 :caption: smithy-build.json
8686
87- {
88- "version": "1.0",
89- "plugins": {
90- + "java-client-codegen": {
91- + "service": "com.example#CoffeeShop", // <- Replace with your service's ID
92- + // Generated Java code will use this as the root package namespace
93- + "namespace": "com.example.cafe"
94- + }
95- }
96- }
87+ {
88+ "version": "1.0",
89+ "plugins": {
90+ + "java-client-codegen": {
91+ + "service": "com.example#CoffeeShop", // <- Replace with your service's ID
92+ + // Generated Java code will use this as the root package namespace
93+ + "namespace": "com.example.cafe"
94+ + }
95+ }
96+ }
9797
9898----------------------------------------
9999Add generated code to the Java sourceSet
@@ -162,7 +162,7 @@ Gradle project to generate a Smithy Java client:
162162 implementation("...")
163163
164164 // Add the client-core dependency needed by the generated code
165- implementation("software.amazon.smithy.java:client-core:__smithy_java_version__"" )
165+ implementation("software.amazon.smithy.java:client-core:__smithy_java_version__")
166166
167167 // Also add your protocol implementations or auth schemes as dependencies
168168 implementation("com.example:my-protocol:1.0.0")
0 commit comments