#22 楼 @wongyouth
#21 楼 @bitbegin 叫做 ServerAuditor,免费的 ssh-client…也是我用过最稳定、最便捷的 ssh 客户端…也有 pad 版。调试部署都在服务端完成啊不可能本地做…剩下的就跟你 ssh 连服务器一样该怎么干怎么干就是了……BTW VNC 免费的客户端推荐Remote VNC
#5 楼 @small_fish__ 不知道能不能这么理解…一般 store 类型数据存入之后每个数据一行,没有数据就存入 nil,hstore 给 hash 单开一行,储存的所有键值都在这一行, 举例说:
User:
id:integer
name:string
extra:hstore
对于
u1 = User.new(
id: 1,
extra: { name: "Bob" }
)
u1.save
#<User id=1, name=nil, extra={'name'=>'Bob'}>
u2 = User.new(
id: 2,
name: "Bob",
extra: { age: 18 }
)
u2.save
#<User id=2, name='Bob', extra={'ago'=>18}>
之类的都是可以同时存在的………一些信息新建、取用更自由更方便……
3.1 The Select and Option Tags The most generic helper is select_tag, which — as the name implies — simply generates the SELECT tag that encapsulates an options string:
<%= select_tag(:city_id, 'Lisbon...') %> This is a start, but it doesn't dynamically create the option tags. You can generate option tags with the options_for_select helper:
<%= options_for_select([['Lisbon', 1], ['Madrid', 2], ...]) %>
output:
Lisbon Madrid ... The first argument to options_for_select is a nested array where each element has two elements: option text (city name) and option value (city id). The option value is what will be submitted to your controller. Often this will be the id of a corresponding database object but this does not have to be the case.
Knowing this, you can combine select_tag and options_for_select to achieve the desired, complete markup:
<%= select_tag(:city_id, > options_for_select(...)) %> options_for_select allows you to pre-select an option by passing its value.
<%= options_for_select([['Lisbon', 1], ['Madrid', 2], ...], 2) %>
output:
Lisbon selected="selected">Madrid ... Whenever Rails sees that the internal value of an option being generated matches this value, it will add the selected attribute to that option.
啊还有这个……管子跳跃躲鸟…http://flynngao.github.io/FlappyTube/
你搜搜看杜蕾斯也做了一个……蝌蚪跳啊跳,躲过各种…
#11 楼 @lidashuang 这是我学习 vim 的原因和动力………
iPhone 全键盘现在打字每分钟 120 字以上无压力……关键在于熟悉…
为什么有一种前端要会的 Rails 工程师都会………………好吧给这个点赞啊看产品思路个人很喜欢的样子!突然觉得 Github 模式可以在更多领域发挥重要作用……嗯………
Nginx 直接读取的是 unicorn 的 socket,所以不用重启 nginx…数据库改动在 database.yml 中加入
host: where.is.your.database
port: 9527 #你数据库开放的端口。比如postgresql默认5432
然后重启就可以了。当然你需要在远程数据库上开放远程登录。以 psql 举例,/etc/postgresql/9.1/main/pg_hba.conf
中需要加入相关信息…以上。
#2 楼 @small_fish__ 在没有太大性能要求的时候用来做 key-value 存储嘛…
正则就行了…
实习生最小招多小的>~<
我是写了个爬虫、一个自动下载新版本工具软件包的脚本、写了个计算基因频率的东西然后就 rails 了………
作为新手顶一个……很多都是常见场景…
顶一个!支持开源!希望参与测试![email protected]
#7 楼 @darkbaby123 主要是风格比较搭
#4 楼 @zhangyanan 那你只能找到 ca s 入口了…
#2 楼 @zhangyanan 这是 cas 的问题啊……可能是读取 ticket 的时候跳转至此或者应用端 cas-client 的设置跳转到了这个页面,你客户端只能找到它所谓的集成入口登录 cas 才行…或者你有源码修改设置…能提供更详细的信息么?