FIX: Plugins may have relative symlinks
This commit is contained in:
parent
a1d660d951
commit
15ae3145ec
|
@ -57,7 +57,11 @@ module Stylesheet
|
||||||
Thread.new do
|
Thread.new do
|
||||||
begin
|
begin
|
||||||
plugins_paths = Dir.glob("#{Rails.root}/plugins/*").map do |file|
|
plugins_paths = Dir.glob("#{Rails.root}/plugins/*").map do |file|
|
||||||
File.symlink?(file) ? File.readlink(file) : file
|
if File.symlink?(file)
|
||||||
|
File.expand_path(File.readlink(file), "#{Rails.root}/plugins")
|
||||||
|
else
|
||||||
|
file
|
||||||
|
end
|
||||||
end.compact
|
end.compact
|
||||||
|
|
||||||
listener = Listen.to("#{root}/#{watch}", listener_opts) do |modified, added, _|
|
listener = Listen.to("#{root}/#{watch}", listener_opts) do |modified, added, _|
|
||||||
|
|
Loading…
Reference in New Issue