diff --git a/docs/publish-sdk.mdx b/docs/publish-sdk.mdx index f4e072e2..7058c1d3 100644 --- a/docs/publish-sdk.mdx +++ b/docs/publish-sdk.mdx @@ -107,8 +107,6 @@ Java and C# require additional setup after running `speakeasy configure publishi #### Java Maven: Sonatype Central Portal (recommended) -For legacy OSSRH publishing support, see the next section. - 1. Create a [Sonatype Central Portal account](https://central.sonatype.org/register/central-portal/) (if needed). 2. Generate a [Sonatype username and password for authentication](https://central.sonatype.org/publish/generate-portal-token/). Save these for step 5. 3. Create a [Sonatype namespace](https://central.sonatype.org/register/central-portal/#choosing-a-namespace). @@ -137,55 +135,8 @@ For legacy OSSRH publishing support, see the next section. companyEmail: info@mycompany.com ``` -#### Java Maven: Sonatype legacy OSSRH -1. Create an [OSSRH staging repository](https://central.sonatype.org/publish/publish-guide/). -2. Create a GPG key to [sign the artifacts](https://central.sonatype.org/publish/requirements/gpg/). Save these for step 3. - - Install GnuPG: `brew install gnupg` - - Generate a key: `gpg --gen-key`. Note the key ID (e.g., `CA925CD6C9E8D064FF05B4728190C4130ABA0F98`) and short ID (e.g., `0ABA0F98`). - - Send the key: `gpg --keyserver keys.openpgp.org --send-keys ` - - Note: The following key servers can also be used: `keyserver.ubuntu.com`, `keys.openpgp.org`, or `pgp.mit.edu` - - Export the secret key: `gpg --export-secret-keys --armor > secret_key.asc` - - The file `secret_key.asc` will contain the GPG secret key. -3. Store the following secrets Github actions secrets: - - `OSSRH_USERNAME` - - `OSSRH_PASSWORD` - - `JAVA_GPG_SECRET_KEY` - - `JAVA_GPG_PASSPHRASE` -4. In the [Speakeasy workflow file](/docs/workflow-file-reference), add `useSonatypeLegacy: true`: -```yaml -workflowVersion: 1.0.0 -speakeasyVersion: latest -sources: - my_source.yaml: - inputs: - - location: my_source.yaml -targets: - java: - target: java - source: my_source.yaml - publish: - java: - #add useSonatypeLegacy: true - useSonatypeLegacy: true - ossrhUsername: test - ossrhPassword: $ossrh_password - gpgSecretKey: $java_gpg_secret_key - gpgPassPhrase: $java_gpg_passphrase -``` -5. In the java section of `gen.yaml`, provide the additional configuration required for publishing to Sonatype legacy: -```yaml - java: - #ensure the `groupID` matches the OSSRH org - groupID: com.example - #ensure the `artificatID` matches the artifact name: - artifactID: example-sdk - ossrhURL: https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/ - githubURL: github.com/org/repo - companyName: My Company - companyURL: https://www.mycompany.com - companyEmail: info@mycompany.com -``` + #### C# NuGet diff --git a/docs/speakeasy-reference/generation/ci-cd-pipeline.mdx b/docs/speakeasy-reference/generation/ci-cd-pipeline.mdx index c7751238..2ab4dc3f 100644 --- a/docs/speakeasy-reference/generation/ci-cd-pipeline.mdx +++ b/docs/speakeasy-reference/generation/ci-cd-pipeline.mdx @@ -169,12 +169,12 @@ secrets: { name: "ossrh_username", description: - "Username for publishing the Java package to the OSSRH repository.", + "Username for publishing the Java package to Sonatype Central Portal.", }, { name: "ossrh_password", description: - "Password for publishing the Java package to the OSSRH repository.", + "Password for publishing the Java package to Sonatype Central Portal.", }, { name: "java_gpg_secret_key", diff --git a/docs/speakeasy-reference/generation/java-config.mdx b/docs/speakeasy-reference/generation/java-config.mdx index f43f6fb1..c7a6ca63 100644 --- a/docs/speakeasy-reference/generation/java-config.mdx +++ b/docs/speakeasy-reference/generation/java-config.mdx @@ -42,7 +42,6 @@ java: java: groupID: "com.mycompany" artifactID: "my-sdk" - ossrhURL: "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/" githubURL: "https://github.com/mycompany/my-sdk" companyName: "My Company" companyURL: "https://www.mycompany.com" @@ -65,13 +64,7 @@ java: description: "The artifact ID used for namespacing the package, usually the name of the project.", }, - { - name: "ossrhURL", - required: "false", - default: "N/A", - description: - "The URL of the staging repository to publish the SDK artifact to.", - }, + { name: "githubURL", required: "for publishing",