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
| // Hi! My name is loadprocess! | |
| // I'am jQuery plugin, part of jQuery Trivial, for show information about | |
| // loading just tell me what you want to do on loading and after that | |
| // and i do that | |
| // | |
| // My bio: | |
| // version: 0.3b (1 April, 2009) | |
| // license: MIT | |
| // | |
| // My creator name is Alexander Koss ([email protected]) |
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
| <ul> | |
| <% if current_user %> | |
| <li><%= link_to_unless_current 'Login', login_path %></li> | |
| <li><%= link_to_unless_current 'Registration', registration_path %></li> | |
| <% else %> | |
| <li><%= link_to_unless_current 'Profile', profile_path %></li> | |
| <li><%= link_to_unless_current 'Settings', settings_path %></li> | |
| <li><%= link_to_unless_current 'Logout', logout_path %></li> | |
| <% end %> | |
| </ul> |
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
| module Loggable | |
| def self.included base | |
| base.send :extend, ClassMethods | |
| end | |
| module ClassMethods | |
| def acts_as_loggable loggable = :all, rules = {} | |
| cattr_accessor :loggable_actions, :loggable_rules | |
| if loggable.class == Hash |
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
| script/generate delayed_job && rake db:migrate | |
| script/delayed_job start |
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 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
| ... | |
| gem 'inherited_resources', :require_as => [] | |
| ... |
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
| CSS({ | |
| '.awesome-style': { | |
| 'background': 'red', | |
| 'color': 'white' | |
| }, | |
| '.one-more-style': { | |
| 'background': 'blue', | |
| 'text-align': 'right' | |
| } |
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
| set :app_file, __FILE__ | |
| set :root, File.dirname(__FILE__) | |
| set :views, 'views' | |
| set :public, 'public' | |
| configure do | |
| Compass.configuration.parse \ | |
| File.join(Sinatra::Application.root, 'config', 'compass.rb') | |
| 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
| module Paperclip | |
| module Storage | |
| module Sftp | |
| def self.extended base | |
| require 'net/ssh' | |
| require 'net/sftp' | |
| base.instance_eval do | |
| @host = @options[:sftp_host] | |
| @user = @options[:sftp_user] |
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
| #!/opt/ruby-enterprise-1.8.7-2010.01/bin/ruby | |
| require 'rubygems' | |
| require 'json' | |
| require 'net/http' | |
| TOKEN = 'YOU_TOKEN' | |
| PROJECTS = [ |