Sha256: 01510a469fae6a353d2a24f657ca05ab7262b3cdce799cfcf50fdf102408b34b

Contents?: true

Size: 429 Bytes

Versions: 10

Compression:

Stored size: 429 Bytes

Contents

# -*- encoding : utf-8 -*-

class UpdateStylesheets < Wagn::CoreMigration
  def up
    dir = File.join data_path, '1.12_stylesheets'
    %w{ common traditional }.each do |sheetname|
      card = Card["style: #{sheetname}"]
      if card && card.pristine?
        card.update_attributes! :content=>File.read("#{dir}/#{sheetname}.scss")
      end
    end
    
    if c = Card['*all+*style+file']
      c.delete!
    end
  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
wagn-1.14.9 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.8 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.7 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.6 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.5 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.4 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.3 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.2 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.1 db/migrate_core_cards/20130920291703_update_stylesheets.rb
wagn-1.14.0 db/migrate_core_cards/20130920291703_update_stylesheets.rb