- version 3.6
Check those constraints:
$this->anything()
| var fs = require('fs'); | |
| var vm = require('vm'); | |
| var emberjs = fs.readFileSync('public/javascripts/vendor/ember-0.9.5.min.js', 'utf8'); | |
| var templatesDir = 'templates'; | |
| var destinationDir = 'public/javascripts/templates'; | |
| function compileHandlebarsTemplate(templatesDir, fileName) { | |
| var file = templatesDir + '/' + fileName; |
| # db/migrate/20111218135715_globalize_models.rb | |
| class GlobalizeModels < ActiveRecord::Migration | |
| def up | |
| NewsItem.create_translation_table!( | |
| {:title => :string, :body => :text}, | |
| {:migrate_data => true} | |
| ) | |
| end |
| App = Ember.Application.create({}); | |
| App.loginController = Ember.Object.create({ | |
| // do login stuff | |
| }); | |
| App.LoginFormView = Ember.View.extend({ | |
| login: null, | |
| password: null, |
| #ifndef DialogManager_h__ | |
| #define DialogManager_h__ | |
| #include <boost/noncopyable.hpp> | |
| #include <boost/function.hpp> | |
| #include "BrowserHost.h" | |
| typedef boost::function<void (const std::string&)> PathCallback; | |
| namespace FB { class PluginWindow; } |
| # GNU Screen - main configuration file | |
| # All other .screenrc files will source this file to inherit settings. | |
| # Author: Christian Wills - [email protected] | |
| # Allow bold colors - necessary for some reason | |
| attrcolor b ".I" | |
| # Tell screen how to set colors. AB = background, AF=foreground | |
| termcapinfo xterm 'Co#256:AB=\E[48;5;%dm:AF=\E[38;5;%dm' |
| # app/models/ability.rb | |
| # All front end users are authorized using this class | |
| class Ability | |
| include CanCan::Ability | |
| def initialize(user) | |
| user ||= User.new | |
| can :read, :all |
| #!/usr/bin/ruby | |
| ORG_ARGV = ARGV.dup | |
| require 'optparse' | |
| require 'socket' | |
| BasicSocket.do_not_reverse_lookup = true | |
| require 'webrick' |