Module: Middleman

Defined in:
lib/middleman-core.rb,
lib/middleman/rack.rb,
lib/middleman-core/rack.rb,
lib/middleman-core/util.rb,
lib/middleman-core/logger.rb,
lib/middleman-core/builder.rb,
lib/middleman-core/sources.rb,
lib/middleman-core/version.rb,
lib/middleman-core/extension.rb,
lib/middleman-core/profiling.rb,
lib/middleman-core/util/data.rb,
lib/middleman-core/util/rack.rb,
lib/middleman-core/extensions.rb,
lib/middleman-core/load_paths.rb,
lib/middleman-core/meta_pages.rb,
lib/middleman-core/util/files.rb,
lib/middleman-core/util/paths.rb,
lib/middleman-core/application.rb,
lib/middleman-core/util/binary.rb,
lib/middleman-core/dns_resolver.rb,
lib/middleman-core/configuration.rb,
lib/middleman-core/file_renderer.rb,
lib/middleman-core/renderers/erb.rb,
lib/middleman-core/sitemap/store.rb,
lib/middleman-core/config_context.rb,
lib/middleman-core/preview_server.rb,
lib/middleman-core/renderers/less.rb,
lib/middleman-core/renderers/sass.rb,
lib/middleman-core/callback_manager.rb,
lib/middleman-core/renderers/liquid.rb,
lib/middleman-core/sitemap/resource.rb,
lib/middleman-core/template_context.rb,
lib/middleman-core/extension_manager.rb,
lib/middleman-core/template_renderer.rb,
lib/middleman-core/renderers/kramdown.rb,
lib/middleman-core/renderers/markdown.rb,
lib/middleman-core/util/uri_templates.rb,
lib/middleman-core/renderers/redcarpet.rb,
lib/middleman-core/core_extensions/data.rb,
lib/middleman-core/preview_server/checks.rb,
lib/middleman-core/sources/source_watcher.rb,
lib/middleman-core/core_extensions/routing.rb,
lib/middleman-core/meta_pages/sitemap_tree.rb,
lib/middleman-core/renderers/coffee_script.rb,
lib/middleman-core/renderers/sass_functions.rb,
lib/middleman-core/meta_pages/config_setting.rb,
lib/middleman-core/preview_server/server_url.rb,
lib/middleman-core/sitemap/extensions/import.rb,
lib/middleman-core/preview_server/information.rb,
lib/middleman-core/sitemap/extensions/ignores.rb,
lib/middleman-core/sitemap/extensions/on_disk.rb,
lib/middleman-core/sitemap/extensions/proxies.rb,
lib/middleman-core/core_extensions/collections.rb,
lib/middleman-core/dns_resolver/hosts_resolver.rb,
lib/middleman-core/meta_pages/sitemap_resource.rb,
lib/middleman-core/core_extensions/file_watcher.rb,
lib/middleman-core/sitemap/extensions/move_file.rb,
lib/middleman-core/sitemap/extensions/redirects.rb,
lib/middleman-core/sitemap/extensions/traversal.rb,
lib/middleman-core/dns_resolver/network_resolver.rb,
lib/middleman-core/preview_server/server_hostname.rb,
lib/middleman-core/preview_server/tcp_port_prober.rb,
lib/middleman-core/core_extensions/external_helpers.rb,
lib/middleman-core/dns_resolver/local_link_resolver.rb,
lib/middleman-core/preview_server/server_ip_address.rb,
lib/middleman-core/preview_server/server_information.rb,
lib/middleman-core/core_extensions/inline_url_rewriter.rb,
lib/middleman-core/dns_resolver/basic_network_resolver.rb,
lib/middleman-core/sitemap/extensions/request_endpoints.rb,
lib/middleman-core/core_extensions/collections/lazy_root.rb,
lib/middleman-core/core_extensions/collections/lazy_step.rb,
lib/middleman-core/core_extensions/collections/pagination.rb,
lib/middleman-core/core_extensions/collections/step_context.rb,
lib/middleman-core/preview_server/network_interface_inventory.rb,
lib/middleman-core/preview_server/server_information_validator.rb,
lib/middleman-core/preview_server/server_information_callback_proxy.rb,
lib/middleman-core/renderers/slim.rb,
lib/middleman-core/renderers/haml.rb

Overview

Routing extension

Defined Under Namespace

Modules: Configuration, CoreExtensions, Extensions, MetaPages, Pagination, Profiling, Renderers, Sass, Sitemap, Util Classes: Application, Builder, CallbackManager, ConfigContext, ConfigExtension, DnsResolver, Extension, ExtensionManager, FileRenderer, Logger, MapDescriptor, MiddlewareDescriptor, PreviewServer, Rack, SourceFile, SourceWatcher, Sources, TemplateContext, TemplateRenderer

Constant Summary collapse

VERSION =

Current Version

Returns:

  • (String)
'4.5.1'.freeze

Class Method Summary collapse

Class Method Details

.serverObject



9
10
11
# File 'lib/middleman/rack.rb', line 9

def self.server
  ::Middleman::Rack.new(::Middleman::Application.new)
end

.setup_load_pathsObject



6
7
8
9
10
11
12
13
14
15
16
17
18
19
# File 'lib/middleman-core/load_paths.rb', line 6

def setup_load_paths
  @_is_setup ||= begin

    # Only look for config.rb if MM_ROOT isn't set
    if !ENV['MM_ROOT'] && (found_path = findup('config.rb'))
      ENV['MM_ROOT'] = found_path
    end

    # If we've found the root, try to setup Bundler
    setup_bundler if ENV['MM_ROOT']

    true
  end
end