Skip to content

Commit

Permalink
Merge pull request #897 from deltalejo/fix/mixins
Browse files Browse the repository at this point in the history
Fix filepath expansion in assemble_mixins().
  • Loading branch information
mkarlesky authored Jun 10, 2024
2 parents ef02690 + fa68e3c commit 12cd524
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions bin/mixinator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ def assemble_mixins(config:, env:, cmdline:)
# 2. Remove duplicates
assembly.uniq! do |entry|
# If entry is filepath, expand it, otherwise leave entry untouched (it's a mixin name only)
@path_validator.filepath?( entry ) ? File.expand_path( entry.values.first ) : entry
mixin = entry.values.first
@path_validator.filepath?( mixin ) ? File.expand_path( mixin ) : mixin
end

# Return the compacted list (in merge order)
Expand Down Expand Up @@ -127,4 +128,4 @@ def merge(builtins:, config:, mixins:)
raise msg if config.empty?
end

end
end

0 comments on commit 12cd524

Please sign in to comment.