fix templates_path on windows
This commit is contained in:
parent
9333763333
commit
1570293c0c
|
@ -1,6 +1,6 @@
|
||||||
module Middleman
|
module Middleman
|
||||||
def self.templates_path
|
def self.templates_path
|
||||||
File.join(`cd ~ && pwd`.chomp, ".middleman")
|
File.join(File.expand_path("~/"), ".middleman")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -17,4 +17,4 @@ end
|
||||||
Dir[File.join(Middleman.templates_path, "*")].each do |dir|
|
Dir[File.join(Middleman.templates_path, "*")].each do |dir|
|
||||||
next unless File.directory?(dir)
|
next unless File.directory?(dir)
|
||||||
Middleman::Templates.register(File.basename(dir).to_sym, Middleman::Templates::Local)
|
Middleman::Templates.register(File.basename(dir).to_sym, Middleman::Templates::Local)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue