最近想弄个能访问 Internet 的 Android 应用,因为求快所以用了 Ruby on
Rails 来提供 HTTP 资源。这方面的资料还是比较少的,所以把尝试的过程记录下来。1 使用 Ruby on Rails构建 Web
Application1.1 新建 Web Application...
分类:
移动开发 时间:
2014-06-19 13:09:55
阅读次数:
427
@include box-shadow(rgba(88,88,88,0.4) 0 0 20px
5px);最后不用的参数就可以不写,rgba可以设透明度alpha,所以在photoshop里面算好rbg值来写也挺好的。上面示例的0 0
是纵向以及横向偏移值。20px是位移,5px是扩散。最后省略了一...
分类:
Web程序 时间:
2014-06-16 09:12:16
阅读次数:
262
1、单行注释用:#2、多行注释用:=begin ...
=end3、语句分隔用;号4、空格在省略()的地方代替()号5、方法定义用:def
undef6、检查类型用:defined?7、变量:全局变量用$,实例变量用@(后面不能直接跟数字),类变量用@@8、输出:puts(每一个变量输出都加一个换行...
分类:
其他好文 时间:
2014-06-13 00:47:40
阅读次数:
301
Execute shell commandsThere are a number of
different ways to run shell commands from Ruby.TheexeccommandKernel#execreplaces
the current process and r...
分类:
其他好文 时间:
2014-06-12 06:50:15
阅读次数:
281
只需要冲定义该对象的
to_yaml_properties 方法, 只返回要序列化的字段就可以了
class A
attr_reader :a
attr_reader :b
def initialize(x,y)
@a = x
@b = y
end
end
a = A.new(1,3)
p a.to_yaml # => "--- !ruby/object:A...
分类:
其他好文 时间:
2014-06-10 15:54:19
阅读次数:
172
如何快速正确的安装 Ruby, Rails 运行环境对于新入门的开发者,如何安装 Ruby,
Ruby Gems 和 Rails 的运行环境可能会是个问题,本页主要介绍如何用一条靠谱的路子快速安装 Ruby
开发环境。次安装方法同样适用于产品环境!系统需求首先确定操作系统环境,不建议在 Window...
分类:
其他好文 时间:
2014-06-09 21:09:32
阅读次数:
231
Bourbon 是一个简单易用的 Sass
混入(Mixin)库,无需配置。该混入包含用于支持所有现代浏览器的 CSS3 属性前缀。前缀需要确保在旧的浏览器支持优雅降级。Bourbon 使用 SCSS
语法。
分类:
其他好文 时间:
2014-06-09 16:50:48
阅读次数:
255
1、apt-get update2、apt-get install
metasploit3、修改文件:/opt/metasploit/ruby/lib/ruby/1.9.1/i686-linux/rbconfig.rb
CONFIG["LIBRUBYARG_STATIC"] = “-Wl,-R -W...
分类:
Web程序 时间:
2014-06-09 15:32:11
阅读次数:
335