Skip to content
Draft
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Run Ruby code
Use the `runCode`/`run_code` method to run Ruby code inside the sandbox.
You'll need to pass the `language` parameter with value `ruby` or `rb`.
<CodeGroup>
```js
import { Sandbox } from '@e2b/code-interpreter'

const sbx = await Sandbox.create()
const execution = await sbx.runCode('puts "Hello, world!"', { language: 'ruby' })
console.log(execution)
```
```python
from e2b_code_interpreter import Sandbox

sbx = Sandbox()
execution = sbx.run_code('puts "Hello, world!"', language="ruby")
print(execution)
```
</CodeGroup>
12 changes: 11 additions & 1 deletion apps/web/src/components/Navigation/routes.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
import { Braces, CheckCircle, Home, KeyRound, MessagesSquare } from 'lucide-react'
import {
Braces,
CheckCircle,
Home,
KeyRound,
MessagesSquare,
} from 'lucide-react'
import sdkRefRoutesJson from './sdkRefRoutes.json'

enum Tag {
Expand Down Expand Up @@ -188,6 +194,10 @@ export const docRoutes: NavGroup[] = [
title: 'R',
href: '/docs/code-interpreting/supported-languages/r',
},
{
title: 'Ruby',
href: '/docs/code-interpreting/supported-languages/ruby',
},
{
title: 'Java',
href: '/docs/code-interpreting/supported-languages/java',
Expand Down