Commit graph

142 commits

Author SHA1 Message Date
Ben Hollis d6110e2ff1 Add a metadata page for inspecting configuration.
This is another metadata page that uses the new configuration system to
show all the available options, their current values, and their defaults.
This is still unstyled, but the info is there. I still need to add on a
method for extensions to register their configuration with the global
config so they show up (stuff like blog) but this is a start.
2013-02-10 16:43:37 -08:00
Ben Hollis 4fe22e3fb5 Move more things over to new configs. Don't let root be configured 2012-10-13 22:37:24 -07:00
Ben Hollis a50ca56fbc Switch over to new config methods 2012-10-13 21:37:02 -07:00
Ben Hollis 781fa1c65f Move configuration into a separate object, that can be reused for extension configuration and makes settings, their defaults, and descriptions inspectable. 2012-10-13 21:36:12 -07:00
Thomas Reynolds c53c46729a actually make ruby encoding setting work, fix gzip to read/write binary 2012-09-29 14:12:26 -07:00
Ben Hollis 8ec42df641 Correctly preview directory URLs with .s in them and show the request path on 404 pages. 2012-09-16 01:57:33 -07:00
Thomas Reynolds 77be952d41 Trying to return from a block is a bad idea 2012-09-13 10:51:31 -07:00
Thomas Reynolds 54c055ea5e Hack a way to pass Middleman context into Slim filters 2012-08-16 13:48:34 -07:00
Thomas Reynolds 446aa6a4ba Clean up whitespace, play with cane for testing style quality and code complexity 2012-08-13 15:41:07 -07:00
Thomas Reynolds f1eae1e0c8 Correct path in sass-assets-path test 2012-07-25 12:05:43 -07:00
Thomas Reynolds 1f6d1a7ee1 Extract load_paths so they aren't locked into the binary 2012-07-19 10:55:14 -07:00
Thomas Reynolds de6d7980ac Use centralized Logger and add instrument methods 2012-07-18 09:30:39 -07:00
kematzy 95339dad23 Added :js_assets_paths for external JS repositories
Please Note!

This fix depends upon support in the 'middleman-sprockets' gem, where the following code must be present:

    # lib/middleman-sprockets/extension.rb
    <snip…>
    append_path app.css_dir

    # add custom assets paths to the scope
    app.js_assets_paths.each do |p|
      append_path p
    end

The purpose of this addition is to support including JS files from external (global) repositories.

Example usage:

    # in config.rb

    set :js_assets_path, [ "#{root}/assets/js/", "~/.js-repo/"]

Using symlinks or copying files to the Middleman project can get messy quickly. This fix reduces some of those issues.
2012-07-17 09:21:46 -07:00
kematzy 3ea2241155 Added :sass_assets_path for external SASS repositories
Compass is great, but sometimes we need to have common framework code in one (global) location with local overrides in the app.

This addition adds built-in support for loading SASS/SCSS files from multiple locations external to the "source" directory and even the Middleman app root.

Example usage:

    # in config.rb

    set :sass_assets_path, [ "#{root}/assets/sass/", "~/.sass-repo/"]

Using symlinks or copying files to the Middleman project can get messy quickly.  This fix reduces some of those issues.
2012-07-17 09:21:46 -07:00
Tim Bates 3cbda0ee36 Added strip_index_file option for configuring urls 2012-07-13 10:57:05 +09:30
Tim Bates 692aa10c8b Add trailing_slash option for prettier urls
"set :trailing_slash, false" will cause resource urls that match the
index_file to have the trailing slash stripped off the directory URL,
e.g. instead of "/dir/index.html" becoming "/dir/" it will be "/dir"
2012-07-12 12:03:33 +09:30
Ben Hollis 1229a9991a Prevent NoMethodError/NameError from hanging the server.
The fix is to work around this bug: http://bugs.ruby-lang.org/issues/4521 where Ruby will call to_s/inspect while printing exception messages, which can take a long time (minutes at full CPU) if the object is huge or has cyclic references, like Middleman::Application does. Defining #to_s short-circuits that. This fixes #370.
2012-07-02 23:39:30 -07:00
Rico Sta. Cruz 96c29181aa Implement the :encoding setting which defaults to 'utf-8' 2012-06-16 06:07:50 +08:00
Daniel Bayerlein cc1a741eb7 Move "set :fonts_dir" from "middleman-more" to "middleman-core". 2012-06-09 20:30:22 +02:00
Thomas Reynolds 2e5b0d75a9 Use pathname consistently in file watcher 2012-05-26 17:48:58 -07:00
Thomas Reynolds 8d483f882c Move Sprockets into an extension 2012-05-26 13:43:27 -07:00
Thomas Reynolds 64f84bacd2 asset urls, padrino helpers and i18n belong in more 2012-05-24 16:31:21 -07:00
Thomas Reynolds 1cad726c81 Move off-by-default extensions into middleman-more, make middleman-more itself an extension 2012-05-24 16:14:17 -07:00
Thomas Reynolds c117415913 Merge pull request #436 from middleman/rack_reloader
Rely on Webrick directly for preview, makes quick app reloading simple.
2012-05-19 22:01:39 -07:00
Thomas Reynolds 3412af346e Rely on Webrick directly for preview, makes quick app reloading simple. 2012-05-19 19:41:22 -07:00
Ben Hollis fc9c5e5fa2 Properly clear frontmatter cache when files change, and calculate frontmatter in the right order so resource_list_manipulators can see it. 2012-05-19 18:47:43 -07:00
Ben Hollis 64a2933161 Remove duplicate server methods and solve webrick logging in a platform-independent way 2012-05-16 21:19:03 -07:00
Thomas Reynolds 7929ed6c75 Refactor Frontmatter to use sitemap manipulators. Also fixes #422 2012-05-08 21:10:41 -07:00
Thomas Reynolds d55fef62b4 Remove usage of autoload statement in favor of require 2012-05-07 14:41:39 -07:00
Thomas Reynolds 7b8457d963 Yard doc cleanup 2 2012-05-02 11:18:16 -07:00
Thomas Reynolds 342044a01d Split out Request handling into an Extension. Dup the Application (like Sinatra) when responding 2012-05-01 13:11:42 -07:00
Ben Hollis 8d6739b15b I shouldn't code late at night 2012-05-01 00:47:36 -07:00
Ben Hollis 8f861fef06 Un-optional a parameter in hopes of fixing rbx build 2012-05-01 00:37:00 -07:00
Ben Hollis 380dac270d Switch content_type param order for 1.8 2012-05-01 00:22:16 -07:00
Ben Hollis 778626c6ec Make Middleman somewhat more threadsafe and switch back to webrick. 2012-04-30 22:38:57 -07:00
Ben Hollis dddd409336 Support Unicode characters in filenames, both in source filenames and in the names of proxied paths. Fixes #332. 2012-04-29 21:42:45 -07:00
Ben Hollis dcc6c5b5e1 Simplify watcher to not fork by using 'listen' in non-blocking mode 2012-04-25 23:21:44 -07:00
Thomas Reynolds 5405af5e0f Merge pull request #372 from bhollis/timing
Add timing info to render logging, and document why we use thin instead of webrick
2012-04-23 10:27:04 -07:00
Ben Hollis c560a0d20e Add timing info to render logging, and document why we use thin instead of webrick 2012-04-23 01:24:16 -07:00
Ben Hollis 0a677f5de1 Reorder extensions so frontmatter is available before sitemap 2012-04-20 23:38:59 -07:00
Thomas Reynolds 8a1342df9c Move Cache into Util 2012-04-14 14:06:49 -07:00
Thomas Reynolds d2d40079cc Rename Middleman::Base to Middleman::Application 2012-04-14 14:04:10 -07:00
Renamed from middleman-core/lib/middleman-core/base.rb (Browse further)