简体   繁体   English

在本地设置红宝石/铁轨沙箱的最简单方法是什么?

[英]what's the easiest way to setup a ruby/rails sandbox locally?

I like to play with dynamic programming languages before I get confident regarding their dynamic behaviors. 在对动态编程语言充满信心之前,我喜欢玩动态编程语言。 While there are online ruby sandbox sources available, I prefer to test it out locally. 虽然有可用的在线红宝石沙箱资源,但我还是希望在本地对其进行测试。

In javascript a html file with script tag is sufficient to write any sample javascript code. 在javascript中,带有script标签的html文件足以编写任何示例javascript代码。

What's the equivalent of forming this sandbox for ruby with...? 用...组成这个红宝石沙箱的等效方式是什么?

1. a boilerplate
2. manually setting up ruby sandbox (prefered)

If you just want a ruby sandbox $ irb will do the trick. 如果您只想要一个红宝石沙盒, $ irb可以解决问题。

If you want a ruby on rails sand box $ rails c -s short for $ rails console ––sandbox . 如果您想在Rails沙盒上使用红宝石,则$ rails c -s$ rails console ––sandbox

This command loads our Rails application, connects to the database and automatically starts a database transaction. 此命令加载我们的Rails应用程序,连接到数据库并自动启动数据库事务。 All database operations performed within this console session are rolled back upon leaving the console. 在离开控制台后,将回滚此控制台会话中执行的所有数据库操作。

到目前为止,BitNami是本地安装最简单的设置: https : //bitnami.com/stack/ruby

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在Ruby on Rails中使用Google Docs API的最简单方法是什么? - What is the easiest way to work with Google Docs API in Ruby on Rails? Windows 7最快的Ruby on Rails设置是什么? - What's the fastest Ruby on Rails setup for Windows 7? 在Rails 3中检测用户操作系统的最简单方法是什么? - What's the easiest way to detect the user's operating system in Rails 3? 在Rails 4中添加真棒字体的最简单方法是什么 - What's the easiest way to add font-awesome in rails 4 将Rails中的子域指向特定控制器的最简单方法是什么? - What's the easiest way to point a subdomain in Rails to a specific controller? 用捆绑器维护一组修补的rails gem的最简单方法是什么? - What's the easiest way to maintain a patched set of rails gems, with bundler? 为此设置使Rails RESTful路由最简单的方法 - Easiest way to make Rails RESTful routes for this setup 尝试在本地Rails上为Ruby设置PostgreSQL - Trying to setup postgresql for ruby on rails locally 在 Ruby on Rails 中找到 60 的除数的最简单方法 - Easiest way to find divisors of 60 in Ruby on Rails 使用Ruby on Rails将几条记录放入数据库的最快,最简单的方法是什么? - What is the fastest, easiest way to get several records into a database using Ruby on Rails?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM