Skip to content

Instantly share code, notes, and snippets.

View kostia's full-sized avatar

Kostia Newt kostia

  • JustRelate
  • Berlin, Germany
View GitHub Profile
// We could also copy this file with `rails g scrivito_editors:install`...
//= require scrivito_editors/binary_editor
//= require scrivito_editors/multienum_editor
//= require scrivito_minicolors_editor
(function() {
scrivit.on('content', function(content) {
if (scrivito.in_editing_view()) {
$(content).find('[data-scrivito-field-type=binary]').scrivito_binary_editor();
@kostia
kostia / upgrade-rails41-to-42-with-rspec2.md
Last active August 29, 2015 14:13
Upgrading Rails 4.1 to 4.2 with RSpec 2

Upgrading Rails 4.1 to 4.2 with RSpec 2

Upgrading Rails is normally a simple task, especially if the difference between the versions is not very large. But in the case of 4.1 to 4.2 upgrade of an application (or a library) using RSpec 2, it can get messy, because RSpec 2 is not fully compatible with Rails 4.2. So in order to upgrade Rails, you have to upgrade RSpec first. Here how we did that:

In order to upgrade to RSpec 3 we first upgrade to RSpec 2.99.0, run the specs to see the deprecations, fix the deprecations and then upgrade to 3.1.0.

  1. First remove all RSpec gems except rspec-rails (all the rspec-* gems).
  2. Then update rspec-rails gem to version 2.99.0.
<?xml version="1.0" encoding="UTF-8" ?>
<Module>
<ModulePrefs title="Hangout Starter">
<Require feature="rpc" />
<Require feature="views" />
<Require feature="locked-domain" />
</ModulePrefs>
<Content type="html"><![CDATA[
<html>