rearrange some requires
This commit is contained in:
parent
deb68c29a7
commit
cfb440e902
|
@ -1,3 +1,8 @@
|
||||||
|
2.0.7
|
||||||
|
=====
|
||||||
|
- Updated HTML5 Boilerplate to v2
|
||||||
|
- Make Rails 3.1 javascript gems available to Sprockets
|
||||||
|
|
||||||
2.0.6
|
2.0.6
|
||||||
=====
|
=====
|
||||||
- Pulled out livereload feature into its own extension, still installed by default.
|
- Pulled out livereload feature into its own extension, still installed by default.
|
||||||
|
|
|
@ -2,6 +2,7 @@ module Middleman::Base
|
||||||
class << self
|
class << self
|
||||||
def registered(app)
|
def registered(app)
|
||||||
# Explicitly require json support
|
# Explicitly require json support
|
||||||
|
require "i18n"
|
||||||
require "active_support"
|
require "active_support"
|
||||||
require "active_support/json"
|
require "active_support/json"
|
||||||
|
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
require 'pathname'
|
||||||
|
require 'rbconfig'
|
||||||
require "sprockets"
|
require "sprockets"
|
||||||
|
|
||||||
module Middleman::CoreExtensions::Sprockets
|
module Middleman::CoreExtensions::Sprockets
|
||||||
|
@ -6,8 +8,18 @@ module Middleman::CoreExtensions::Sprockets
|
||||||
app.set :js_compressor, false
|
app.set :js_compressor, false
|
||||||
|
|
||||||
app.after_configuration do
|
app.after_configuration do
|
||||||
|
js_env = Middleman::CoreExtensions::Sprockets::JavascriptEnvironment.new(app)
|
||||||
|
|
||||||
|
js_dir = File.join("vendor", "assets", "javascripts")
|
||||||
|
gems_with_js = ::Middleman.rubygems_latest_specs.select do |spec|
|
||||||
|
::Middleman.spec_has_file?(spec, js_dir)
|
||||||
|
end.each do |spec|
|
||||||
|
js_env.append_path File.join(spec.full_gem_path, js_dir)
|
||||||
|
end
|
||||||
|
|
||||||
|
# add paths to js_env (vendor/assets/javascripts)
|
||||||
app.map "/#{app.js_dir}" do
|
app.map "/#{app.js_dir}" do
|
||||||
run Middleman::CoreExtensions::Sprockets::JavascriptEnvironment.new(app)
|
run js_env
|
||||||
end
|
end
|
||||||
|
|
||||||
# app.map "/#{app.css_dir}" do
|
# app.map "/#{app.css_dir}" do
|
||||||
|
@ -38,13 +50,6 @@ module Middleman::CoreExtensions::Sprockets
|
||||||
|
|
||||||
# configure search paths
|
# configure search paths
|
||||||
append_path app.js_dir
|
append_path app.js_dir
|
||||||
|
|
||||||
# jQuery for Sprockets
|
|
||||||
# begin
|
|
||||||
# require "jquery-rails"
|
|
||||||
# jquery-rails / vendor / assets / javascripts
|
|
||||||
# rescue LoadError
|
|
||||||
# end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def javascript_exception_response(exception)
|
def javascript_exception_response(exception)
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
module Middleman
|
module Middleman
|
||||||
VERSION = "2.0.6"
|
VERSION = "2.0.7"
|
||||||
end
|
end
|
||||||
|
|
|
@ -37,40 +37,42 @@ Gem::Specification.new do |s|
|
||||||
********************************************************************************
|
********************************************************************************
|
||||||
eos
|
eos
|
||||||
|
|
||||||
s.add_runtime_dependency("rack", ["~> 1.3.0"])
|
s.add_dependency("rack", ["~> 1.3.0"])
|
||||||
s.add_runtime_dependency("thin", ["~> 1.2.11"])
|
s.add_dependency("thin", ["~> 1.2.11"])
|
||||||
s.add_runtime_dependency("thor", ["~> 0.14.0"])
|
s.add_dependency("thor", ["~> 0.14.0"])
|
||||||
s.add_runtime_dependency("tilt", ["~> 1.3.1"])
|
s.add_dependency("tilt", ["~> 1.3.1"])
|
||||||
s.add_runtime_dependency("maruku", ["~> 0.6.0"])
|
s.add_dependency("maruku", ["~> 0.6.0"])
|
||||||
s.add_runtime_dependency("sinatra", ["~> 1.2.6"])
|
s.add_dependency("sinatra", ["~> 1.2.6"])
|
||||||
s.add_runtime_dependency("rack-test", ["~> 0.6.1"])
|
s.add_dependency("rack-test", ["~> 0.6.1"])
|
||||||
s.add_runtime_dependency("uglifier", ["~> 1.0.0"])
|
s.add_dependency("uglifier", ["~> 1.0.0"])
|
||||||
s.add_runtime_dependency("slim", ["~> 1.0.1"])
|
s.add_dependency("slim", ["~> 1.0.1"])
|
||||||
s.add_runtime_dependency("haml", ["~> 3.1.0"])
|
s.add_dependency("haml", ["~> 3.1.0"])
|
||||||
s.add_runtime_dependency("sass", ["~> 3.1.7"])
|
s.add_dependency("sass", ["~> 3.1.7"])
|
||||||
s.add_runtime_dependency("compass", ["~> 0.11.3"])
|
s.add_dependency("compass", ["~> 0.11.3"])
|
||||||
s.add_runtime_dependency("coffee-script", ["~> 2.2.0"])
|
s.add_dependency("coffee-script", ["~> 2.2.0"])
|
||||||
s.add_runtime_dependency("sprockets", ["2.0.0.beta.15"])
|
s.add_dependency("sprockets", ["2.0.0.beta.15"])
|
||||||
|
|
||||||
# Padrino deps
|
# Padrino deps
|
||||||
s.add_runtime_dependency("activesupport", "~> 3.0.0")
|
s.add_dependency("activesupport", "~> 3.0.0")
|
||||||
|
|
||||||
# Only in Padrino-helpers
|
# Only in Padrino-helpers
|
||||||
s.add_runtime_dependency("i18n", "~> 0.5.0")
|
s.add_dependency("i18n", "~> 0.5.0")
|
||||||
|
|
||||||
case Config::CONFIG['host_os'].downcase
|
case Config::CONFIG['host_os'].downcase
|
||||||
when %r{mswin|mingw}
|
when %r{mswin|mingw}
|
||||||
# s.add_runtime_dependency "windows-api", "= 0.4.0"
|
# s.add_runtime_dependency "windows-api", "= 0.4.0"
|
||||||
# s.add_runtime_dependency "windows-pr", "= 1.1.2"
|
# s.add_runtime_dependency "windows-pr", "= 1.1.2"
|
||||||
s.add_runtime_dependency("win32-process", ["~> 0.6.5"])
|
s.add_dependency("win32-process", ["~> 0.6.5"])
|
||||||
s.add_runtime_dependency("win32console", ["~> 1.3.0"])
|
s.add_dependency("win32console", ["~> 1.3.0"])
|
||||||
s.add_runtime_dependency("rb-fchange")
|
s.add_dependency("rb-fchange")
|
||||||
when %r{darwin}
|
when %r{darwin}
|
||||||
s.add_runtime_dependency("rb-fsevent", ["~> 0.4.2"])
|
s.add_dependency("rb-fsevent", ["~> 0.4.2"])
|
||||||
end
|
end
|
||||||
|
|
||||||
s.add_runtime_dependency("guard", ["~> 0.6.2"])
|
s.add_dependency("guard", ["~> 0.6.2"])
|
||||||
s.add_runtime_dependency("middleman-livereload", ["~> 0.2.0"])
|
s.add_dependency("middleman-livereload", ["~> 0.2.0"])
|
||||||
|
|
||||||
|
# Development and test
|
||||||
s.add_development_dependency("coffee-filter", ["~> 0.1.1"])
|
s.add_development_dependency("coffee-filter", ["~> 0.1.1"])
|
||||||
s.add_development_dependency("cucumber", ["~> 1.0.2"])
|
s.add_development_dependency("cucumber", ["~> 1.0.2"])
|
||||||
s.add_development_dependency("rake", ["0.8.7"])
|
s.add_development_dependency("rake", ["0.8.7"])
|
||||||
|
|
Loading…
Reference in a new issue