This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # This is the default configuration file with all checking enabled. It is also | |
| # the configuration used to check the rubocop source code. | |
| # Use UTF-8 as the source file encoding. | |
| Encoding: | |
| Enabled: true | |
| # Limit lines to 80 characters. | |
| LineLength: | |
| Enabled: true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # -*- coding: utf-8 -*- | |
| puts "gist.vim test" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Dir.glob("app/models/*.rb"). | |
| map{|m|m.gsub("app/models/", "")}. | |
| map{|m| m.gsub(".rb", "")}.each do |m| | |
| clazz = m.classify.constantize | |
| next unless clazz.kind_of?(ActiveRecord::Base) | |
| clazz.delete_all | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [:action1, :action2].each do |a| | |
| it "should be successfl" do | |
| get a | |
| response.should be_success | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # -*- coding: utf-8 -*- | |
| a= [1, 2, 3] | |
| for v in a | |
| b = 'a' | |
| puts v | |
| end | |
| puts b | |
| a.each do |v| | |
| c = 'a' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo apt-get update | |
| sudo apt-get install build-essential -y | |
| sudo apt-get install curl -y | |
| sudo apt-get install sysstat -y | |
| sudo apt-get install ssh -y | |
| sudo apt-get install screen -y | |
| sudo apt-get install zsh -y | |
| #lua for vim | |
| sudo apt-get install liblua5.2-dev -y |
NewerOlder