Sha256: ccb2e02ead5bc8d8c00f7525870d72eb10fe4c2d411a59cd9d0bc819f9c4b39e

Contents?: true

Size: 404 Bytes

Versions: 112

Compression:

Stored size: 404 Bytes

Contents

require 'singleton'

module Scrivito
  module Migrations
    class MigrationStore
      include Singleton

      def backend
        @backend ||= CmsBackend.new
      end

      def versions
        @versions ||= MultiJson.load(backend.read.presence || '[]')
      end

      def add_version(version)
        versions << version
        backend.save(MultiJson.dump(versions))
      end
    end
  end
end

Version data entries

112 entries across 112 versions & 1 rubygems

Version Path
scrivito_sdk-1.16.0 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.16.0.rc2 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.16.0.rc1 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.15.0 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.15.0.rc2 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.15.0.rc1 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.14.0 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.14.0.rc3 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.14.0.rc2 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.14.0.rc1 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.13.0 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.13.0.rc2 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.13.0.rc1 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.12.0 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.12.0.rc2 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.12.0.rc1 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.11.0 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.11.0.rc1 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.10.0 app/cms/scrivito/migrations/migration_store.rb
scrivito_sdk-1.10.0.rc5 app/cms/scrivito/migrations/migration_store.rb