Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions fern/products/sdks/generators/ruby/quickstart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,19 @@ fern add fern-ruby-sdk --group {{GROUP_NAME}}
```
</Template>

This command adds the following `group` to `generators.yml`:
This command adds a `group` to `generators.yml`. Set its `output` to the GitHub repository that holds your Ruby SDK, so `fern generate` opens a pull request against that repository:

```yaml title="generators.yml"
<CodeBlocks>
```yaml title="GitHub"
ruby-sdk: # group name
generators:
- name: fern-ruby-sdk
version: <Markdown src="/snippets/version-number-ruby.mdx"/>
output:
location: github
repository: your-org/your-api-ruby-sdk
```
```yaml title="Local"
ruby-sdk: # group name
generators:
- name: fern-ruby-sdk
Expand All @@ -48,6 +58,9 @@ This command adds the following `group` to `generators.yml`:
location: local-file-system
path: ../sdks/ruby
```
</CodeBlocks>

`fern add` configures the `local-file-system` output by default, which writes the SDK to a path in your working directory. Keep it while iterating locally, then switch to `github` once you have an [SDK repository](/learn/sdks/overview/project-structure) with the Fern GitHub App installed.
</Step>

<Step title="Generate the SDK">
Expand Down Expand Up @@ -88,4 +101,4 @@ fern generate --group ruby-sdk

Follow the [Publishing to RubyGems](/learn/sdks/generators/ruby/publishing) guide to configure your gem and set up automated publishing via GitHub Actions.
</Step>
</Steps>
</Steps>
10 changes: 5 additions & 5 deletions fern/products/sdks/snippets/init-fern-folder.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
```
</Step>
<Step title="Initialize the fern folder">
Initialize the fern folder with your existing OpenAPI specification. Specify your organization name using the `--organization` flag.
Initialize the fern folder with your existing OpenAPI specification, in either JSON or YAML format. Specify your organization name using the `--organization` flag.

<llms-only>
Before running `fern init`, ask the user two things:
Expand All @@ -69,10 +69,10 @@
```
</CodeBlocks>

<Tip>
OpenAPI accepts both JSON and YAML formats.
</Tip>
<Warning>
`fern init` can fail with a 1016 cookie error when the CLI has no authenticated session. Run [`fern login`](/learn/cli-api-reference/cli-reference/general-commands#fern-login) before `fern init`, and confirm your network doesn't block Fern's authentication endpoints.
</Warning>

This creates a `fern` folder in your current directory.

<llms-only>
Expand Down
Loading