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
| #user nobody; | |
| worker_processes 1; | |
| #error_log logs/error.log; | |
| #error_log logs/error.log notice; | |
| #error_log logs/error.log info; | |
| #pid logs/nginx.pid; |
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
| #user nobody; | |
| worker_processes 1; | |
| #error_log logs/error.log; | |
| #error_log logs/error.log notice; | |
| #error_log logs/error.log info; | |
| #pid logs/nginx.pid; |
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 installer has already modified the configuration file for you! The | |
| following configuration snippet was inserted: | |
| http { | |
| ... | |
| passenger_root /Users/sumitasok/.rvm/gems/ruby-1.9.3-p392@ehq/gems/passenger-4.0.5; | |
| passenger_ruby /Users/sumitasok/.rvm/wrappers/ruby-1.9.3-p392@ehq/ruby; | |
| ... | |
| } |
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
| #user nobody; | |
| worker_processes 1; | |
| #error_log logs/error.log; | |
| #error_log logs/error.log notice; | |
| #error_log logs/error.log info; | |
| #pid logs/nginx.pid; |
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
| map - like method definition | |
| root - root path off the app | |
| index - index file of the project | |
| $http_user_agent - User Agent: Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_2 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8H7 Safari/6533.18.5 | |
| $request - Request: "GET /hhh?desktop_view HTTP/1.1" | |
| $args - ARGS: "desktop_view" | |
| $remote_addr - 127.0.0.1 | |
| $remote_user | |
| $time_local - 03/Jun/2013:19:45:20 +0530 |
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
| ruby -ryaml -rjson -e 'puts YAML.dump(JSON.parse(STDIN.read))' < file.json > file.yaml |
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
| it { should validate_presence_of :abc } | |
| # what it expects is error messages against the columns which are under question. | |
| # if you have a custom error message, use | |
| it { should validate_presence_of(:abc).with_message(/the message/) } |
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
| class UserDefined | |
| module ActionController # :nodoc: all | |
| def self.included(base) | |
| base.send :helper_method, :user_method | |
| end | |
| private | |
| def user_method | |
| @user_defined ||= UserDefined.new( | |
| :var => 'value', |
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
| <form> | |
| <fieldset> | |
| <legend>Form header</legend> | |
| <! this above fieldset legend should have the text explaining the forms purpose > | |
| <label for="id_of_related_input_field">Text corresponding to input field</label> | |
| <input id="id_of_related_input_field" type="..." /> | |
| <! have label close to input, have for(label) and id(input) same for identification by screen reader, prefer this way over nesting input under label > |
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
| # to get the Location from the response header. | |
| response.header["Location"].should eq('/admin/clients/'+client.id+'/edit') |