Linux operating system: CentOS6.3 64bitruby:ruby-2.0.0-p247
I. Installing the development pack (using the default CentOS update source)
Copy Code code as follows:
# yum Install openssl* openssl-devel zlib-devel gcc gcc-c++ make
In the process of using ruby/rails, it is found that sometimes performance is unsatisfactory, such as the generation of a 3-layer tree with 600 items of the directory to spend 20ms, in order to improve performance in the learning to write Ruby
Environment configuration
Before using Ruby to encode or decode JSON data, we need to install the Ruby JSON module first. Before installing the module you need to install Ruby Gem, and we use Ruby Gem to install the JSON module. However, if you are
Some databases support a Boolean type, while others do not, making it difficult for an active record to abstract a Boolean type. For example, if the database does not support Boolean types, some developers use char (1) Instead, and the content uses "
Ruby on Rails is a software package for writing network applications. It's based on a computer software language, Ruby, Provides powerful framework support for program developers. You can write first-class networking software with less code and a
Switching from Java to Ruby is a significant change for programmers. Rava makes this migration process a bit more comfortable.QuotesI can write Java in any language.--AnonInstallationTo install using gem:sudo gem install Jimmeirich-ravaUsageRequire '
Recently, many people have emailed me all the vim packages. Download is provided below. You just need to download them. You don't have to send me any more emails. Of course, you are welcome to leave a message on my blog.
Now vim-Ruby is installed.
View
View is divided into builder mode and rhtml mode.
The following is an example of the builder mode.
XML. Div (: class => "productlist") DoXML. timestamp (time. Now)@ Products. Each do | product |XML. Product doXML. productname (product.
Recently, to learn new projects, you need to learn new languages to complete tasks. This language is Ruby that has been heard but never learned and practiced, the previous visual image is often used in comparison with python. Of course, it is a
Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/-->Chmod777 *. Sh
Yesterday afternoon I 've been debugging How to Use Net: SSH in Ruby to call Linux script files.
The basic Linux
For Ruby introduction, see: http://www.ruby-lang.org/zh_CN/about/
I. IRB
Interactive Ruby help and consoleProgramIn Windows.
You can directly execute Ruby in IRB.Code. For example:
Code highlighting produced by Actipro CodeHighlighter
Http://guides.rubyonrails.org/v3.0.8/action_controller_overview.html#the-flash
How to display the error message in controller on the page,
The Flash is a special part of the session which is cleared with each request. this means that values stored
There are two forms of Ruby case expressions:
The first form is similar to a set of continuous if statements: it allows you to list a set of conditions and execute the first statement corresponding to the true condition expression.
In the second
This is a research note, mainly to consult with you. In addition to the beginning, there is no extra nonsense, and no other customer experience is required. Please do not complain about poor readability.
1. Add a colon Before a name or string to get
Development Environment
OS: Windows XP
RUBY: ruby1.8.7
Rails: rails2.3.5
MySQL: mysql5.0.9
IDE: rubymine2.0.1
Preparations:
Install the following gem package
Gem install ruport
Gem install ruport-util
Gem install acts_as_reportable
In this
Http://www.songlin51.com/archives/667.html
Ubuntu 12.04 redmine2.1 installation record
When you install gem install rails, you cannot connect to rails.
Solution: Search for railson http://rubygems.org/gems/railsto download rails. gem for
Jira4r is a Ruby library used to operate the JIRA problem tracking system.Installation requirements (in Windows ):1. Ruby2. soap4r (gem install soap4r)3. jira4r (gem install jira4r)
If the 'xml processor module not found 'error message appears
Previously we tested model and controller and learned some common test methods. Now we will go deep into several test topics. The first is to use a Mock object.
In many cases, our programs are dependent on the actual environment, such as the
1. quickly obtain the matching value of a regular expression
We usually use a regular expression to match the expression first and then obtain the result, but sometimes an exception is thrown. See the following example:
Copy codeThe Code is as
Details about the association between models in ruby on rails: rubyrails
Preface:Before learning model Association, remember the following points:1. Link. Both ends must be written. Otherwise, errors that beginners cannot understand may occur. It is
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service