Skip to content

Commit

Permalink
Revert "Merge pull request solidusio#93 from solidusio/revert-flickwerk"
Browse files Browse the repository at this point in the history
This reverts commit de20d69, reversing
changes made to 373d51c.
  • Loading branch information
mamhoff committed Dec 18, 2024
1 parent 2b2d179 commit 04b1f15
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
13 changes: 13 additions & 0 deletions lib/solidus_support/engine_extensions.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# frozen_string_literal: true

require "active_support/deprecation"
require "flickwerk"

module SolidusSupport
module EngineExtensions
Expand All @@ -9,6 +10,7 @@ module EngineExtensions

def self.included(engine)
engine.extend ClassMethods
engine.include Flickwerk

engine.class_eval do
solidus_decorators_root.glob('*') do |decorators_folder|
Expand Down Expand Up @@ -105,6 +107,17 @@ def enable_solidus_engine_support(engine)
end
end
end

initializer "#{name}_#{engine}_patch_paths", before: "flickwerk.add_paths" do
patch_paths = root.join("lib/patches/#{engine}").glob("*")
Flickwerk.patch_paths += patch_paths
end

initializer "#{name}_#{engine}_user_patches", before: "flickwerk.add_patches" do
Flickwerk.patches.transform_keys! do |key|
key.gsub("Spree.user_class", Spree.user_class_name)
end
end
end
end
end
Expand Down
3 changes: 3 additions & 0 deletions solidus_support.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ Gem::Specification.new do |spec|
spec.executables = files.grep(%r{^exe/}) { |f| File.basename(f) }
spec.require_paths = ["lib"]

spec.add_dependency 'flickwerk', '~> 0.2.0'
spec.add_dependency 'solidus_core', '~> 4.1'

spec.add_development_dependency 'rails'
spec.add_development_dependency 'bundler'
spec.add_development_dependency 'rake'
Expand Down

0 comments on commit 04b1f15

Please sign in to comment.