(原稿)在 Windows下安装开源REST项目altered_beast
一、安装ruby,rubygems,rails
参考:http://www.rubyonrailscn.org/down/
1,下载并安装Ruby 1.8.7。
(注:altered_beast需要rails 2.3.3,而rails 2.3.3又至少需要Ruby 1.8.7)
2,下载rubygems-1.3.7,进入下载目录后通过命令ruby setup.rb来安装。
3,安装Rails。通过执行:gem install rails 2.3.3来安装
4,rails项目测试:
rails test
cd test
ruby script/server
你开始运行Ruby on Rails了!就这么简单。
访问 http://localhost:3000 即可看到web页面,获得进一步指南!
二、安装mysql
略。
三、运行beast源代码
参考:
http://balagan.org.uk/software-development/ruby-on-rails/installing-altered_beast-on-windows.htm
http://hlee.iteye.com/blog/544849
1,在https://github.com/courtenay/altered_beast中下载源代码,可以新建altered_beast文件夹,放入其中
2,运行如下命令:
cd altered_beast
mkdir log
rake tmp:create
cd /config
ren database.sample.yml database.yml
cd ..
(注:此时直接运行rake gems:install会失败,可能由于environment.rb中config.gem不正确,所以我们一个个gem安装)
gem install rspec
gem install rspec-rails
gem install highline
gem install RedCloth -v 3.0.4
gem install bluecloth -v 2.0.7
(注:注意版本,否则会安装不成功)
gem install ruby-openid
gem install mysql
3,直接运行gem install ruby-debug会失败
需要手工下载与windows兼容的ruby-debug,下载地址
http://rubyforge.iasi.roedu.net/gems/ruby-debug-base-0.9.2-mswin32.gem
http://rubyforge.iasi.roedu.net/gems/ruby-debug-ide-0.1.3.gem
http://rubyforge.iasi.roedu.net/gems/ruby-debug-0.9.2.gem
然后,在命令行中进入下载目录,依次执行
gem install ruby-debug-base-0.9.2-mswin32.gem
gem install ruby-debug-ide-0.1.3.gem
gem install ruby-debug-0.9.2.gem
完成ruby-debug的安装
4,(1)建立数据库
mysqladmin -u root create altered_beast
mysqladmin -u root create altered_beast_test
(注:如果有密码,需要mysqladmin -u root -p create altered_beast,输入你的密码)
(2)配置database.yml并初始化amdin user
rake app:bootstrap
(注:此处根据提示来操作即可)
5,运行beast项目:ruby script/server,地址为http://localhost:3000
分享到:
相关推荐
Altered small world brain functional networks.pdf
图像以 base64 数据 URL 的形式存储在两个 .txt 文件(painting/altered_painting)中。 当第一次运行 app.js 时,两者都会被生成+创建。 设置: 按照说明安装 node-canvas @ 更改 views/index.ejs 中的套接字...
用于图像识别,对于图像检测这一块非常有用
步骤2:在scott用户下创建test_emp表: SQL> conn scott/tiger; Connected. SQL> select * from tab; TNAME ? ? ? TABTYPE CLUSTERID ------------------------------ ------- ---------- BONUS ? ? ? TABLE...
altered_code / RandomLatticeTG_ShortMoveOut_mod2 [...]。wl mathematica / my_code / probList.wl sze_entropy []:使用work / probArrays来观察可观察对象在循环中的行为。 我不相信... (**)数学 my_c
启动数据库到mount状态下 SQL> STARTUP MOUNT; Java代码 收藏代码 ORACLE instance started. Total System Global Area 76619308 bytes Fixed Size 454188 bytes Variable Size 58720256 bytes Database ...
Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution.
The document may not be modified or altered in any way. Except where your use constitutes "fair use" under copyright law, you may not use, share, download, upload, copy, print, display, perform, ...
An altered proliferation response due to the anticonvulsant phenytoin (PHT) in epileptic patients Teratogenesis, Carcinogenesis, and Mutagenesis 21:151–164 (2001) :copyright: 2001 Wiley-Liss, Inc...
病毒侵染对寄主番茄花和果子microRNAs及其靶标mRNAs表达的影响,林若虹,冯俊丽,番茄不仅具有重要的经济价值,并且番茄已成为研究肉质果子成熟和发育的模式植物。microRNA(miRNAs)是一类小的内源RNAs,它参与植物体...
Cellular damage and altered carbohydrate expression in P815 tumor cells induced by direct electric current: An in vitro analysis Bioelectromagnetics 21:597^607 (2000) Cellular Damage and Altered ...
ctrlp 改变 最近修改的文件的 ctrlp.vim 扩展名。...安装 使用 : NeoBundle 'i2bskn/ctrlp-altered', { \ 'depends' : 'ctrlpvim/ctrlp.vim', \ } 用法 在 ctrlp 中打开最近修改的文件。 :CtrlPAltered
Quantitative analysis of the altered gait variability in patients with amyotrophic lateral sclerosis (ALS) will be helpful for either diagnosing or monitoring pathological progression of the disease....
Electronic Properties of Graphene Altered by Substrate Surface Chemistry and Externally Applied Electric Field
ALTEREDSTATES
Nginx上传模块该模块基于Nginx上传模块(v 2.2.0) 。 ...由于似乎作者没有维护该... } # Upload form should be submitted to this location location /upload { # Pass altered request body to this location uploa
The data in this document may not be altered or amended without special noti- fication from ETAS GmbH. ETAS GmbH undertakes no further obligation in rela- tion to this document. The software described...
Constructor scope altered to public for base class to instantiate.
⾸先我们找到⾃⼰的MDK的安装路径,进⼊到ARM\Flash⽂件夹下(例如: D:\Keil_v5\ARM\Flash)。 这⾥有个编程算法的⼯程模板,复制这个⼯程到你的⼯程⽂件夹下,重命名你⾃⼰的想要的名字。 打开⼯程,⾥⾯主要有两...
The code is for PMU placement algorithm considering both the channel limit and the cost of PMUs. The F matrix can be altered to change the cost at every bus and the number of channels can be selected.