重新整理一下 restful-authentication的安装

有些东西忘的太快了 。 mysql 不知道安装过多少次 ,最终有些命令总是丢三落四的 。 最终 一个文档 把它全部终结 。

首先 安装 状态机 state_machine

安装地址:http://github.com/pluginaweek/state_machine/tree/master
这个状态机 已经被 aasm 取代 ,建议安装后者 。 我这里 需求简单 ,仅仅是记录用户的验证状态 ,无所谓了 。

安装 rspec
地址:http://wiki.github.com/dchelimsky/rspec/rails

Rspec 的安装方法在:http://wiki.github.com/dchelimsky/rspec/rails 说的很明白.可是我也遇到了问题 :
我在window上 直接按照 如下方法安装
ruby script/plugin install git://github.com/dchelimsky/rspec.git -r 'refs/tags/1.2.6'
ruby script/plugin install git://github.com/dchelimsky/rspec-rails.git -r 'refs/tags/1.2.6'
ruby script/generate rspec

结果失败 , 最后无奈 只能用 git clone 拷贝 源码到plugin下, 最后 执行
ruby script\generate rspec 才成功 。

一般情况 , 按照 以上的步骤应该没问题才对 。

安装 restful-authentication
地址:http://github.com/technoweenie/restful-authentication/tree/master
如果以上 准备就行 ,按照 这个插件里面的README.textile 安装 应该没问题了:

./script/generate authenticated user sessions \
--include-activation \
--stateful \
--rspec \
--skip-migration \
--skip-routes \
--old-passwords
我将 --skip-migration \ --skip-routes \ 去掉了 , 生成migration吧 不行的话,省了手工建文件 。
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值