middleman 1.0.2 → 1.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/middleman/builder.rb +2 -3
- data/lib/middleman/server.rb +4 -2
- data/lib/middleman/version.rb +1 -1
- metadata +8 -55
    
        data/lib/middleman/builder.rb
    CHANGED
    
    | @@ -6,9 +6,6 @@ require 'middleman/templater+dynamic_renderer.rb' | |
| 6 6 | 
             
            module Middleman
         | 
| 7 7 | 
             
              class Builder < ::Templater::Generator
         | 
| 8 8 |  | 
| 9 | 
            -
                # Support all Tilt-enabled templates and treat js like a template
         | 
| 10 | 
            -
                @@template_extensions = ::Tilt.mappings.keys << "js"
         | 
| 11 | 
            -
                
         | 
| 12 9 | 
             
                # Define source and desintation
         | 
| 13 10 | 
             
                def self.source_root; Dir.pwd; end
         | 
| 14 11 | 
             
                def destination_root; File.join(Dir.pwd, Middleman::Server.build_dir); end
         | 
| @@ -43,6 +40,8 @@ module Middleman | |
| 43 40 | 
             
                end
         | 
| 44 41 |  | 
| 45 42 | 
             
                def self.init!
         | 
| 43 | 
            +
                  # Support all Tilt-enabled templates and treat js like a template
         | 
| 44 | 
            +
                  @@template_extensions ||= ::Tilt.mappings.keys << "js"
         | 
| 46 45 | 
             
                  glob! File.basename(Middleman::Server.public),  @@template_extensions
         | 
| 47 46 | 
             
                  glob! File.basename(Middleman::Server.views),   @@template_extensions
         | 
| 48 47 | 
             
                end
         | 
    
        data/lib/middleman/server.rb
    CHANGED
    
    | @@ -97,7 +97,7 @@ module Middleman | |
| 97 97 | 
             
                def self.page(url, options={}, &block)
         | 
| 98 98 | 
             
                  url << settings.index_file if url.match(%r{/$})
         | 
| 99 99 |  | 
| 100 | 
            -
                  options[:layout]  | 
| 100 | 
            +
                  options[:layout] = current_layout if options[:layout].nil?
         | 
| 101 101 | 
             
                  get(url) do
         | 
| 102 102 | 
             
                    return yield if block_given?
         | 
| 103 103 | 
             
                    process_request(options)
         | 
| @@ -119,7 +119,9 @@ module Middleman | |
| 119 119 |  | 
| 120 120 | 
             
                  old_layout = settings.current_layout
         | 
| 121 121 | 
             
                  settings.layout(options[:layout]) if !options[:layout].nil?
         | 
| 122 | 
            -
                   | 
| 122 | 
            +
                  layout = settings.fetch_layout_path.to_sym
         | 
| 123 | 
            +
                  layout = false if options[:layout] == false or path =~ /\.(css|js)$/
         | 
| 124 | 
            +
                  result = render(path, :layout => layout, :layout_engine => options[:layout_engine])
         | 
| 123 125 | 
             
                  settings.layout(old_layout)
         | 
| 124 126 |  | 
| 125 127 | 
             
                  if result
         | 
    
        data/lib/middleman/version.rb
    CHANGED
    
    
    
        metadata
    CHANGED
    
    | @@ -1,13 +1,13 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification 
         | 
| 2 2 | 
             
            name: middleman
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version 
         | 
| 4 | 
            -
              hash:  | 
| 5 | 
            -
              prerelease:  | 
| 4 | 
            +
              hash: 17
         | 
| 5 | 
            +
              prerelease: 
         | 
| 6 6 | 
             
              segments: 
         | 
| 7 7 | 
             
              - 1
         | 
| 8 8 | 
             
              - 0
         | 
| 9 | 
            -
              -  | 
| 10 | 
            -
              version: 1.0. | 
| 9 | 
            +
              - 3
         | 
| 10 | 
            +
              version: 1.0.3
         | 
| 11 11 | 
             
            platform: ruby
         | 
| 12 12 | 
             
            authors: 
         | 
| 13 13 | 
             
            - Thomas Reynolds
         | 
| @@ -15,7 +15,7 @@ autorequire: | |
| 15 15 | 
             
            bindir: bin
         | 
| 16 16 | 
             
            cert_chain: []
         | 
| 17 17 |  | 
| 18 | 
            -
            date:  | 
| 18 | 
            +
            date: 2011-01-05 00:00:00 -08:00
         | 
| 19 19 | 
             
            default_executable: 
         | 
| 20 20 | 
             
            dependencies: 
         | 
| 21 21 | 
             
            - !ruby/object:Gem::Dependency 
         | 
| @@ -443,56 +443,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement | |
| 443 443 | 
             
            requirements: []
         | 
| 444 444 |  | 
| 445 445 | 
             
            rubyforge_project: middleman
         | 
| 446 | 
            -
            rubygems_version: 1. | 
| 446 | 
            +
            rubygems_version: 1.4.1
         | 
| 447 447 | 
             
            signing_key: 
         | 
| 448 448 | 
             
            specification_version: 3
         | 
| 449 449 | 
             
            summary: A static site generator utilizing Haml, Sass and providing YUI compression and cache busting
         | 
| 450 | 
            -
            test_files: 
         | 
| 451 | 
            -
             | 
| 452 | 
            -
            - features/coffee-script.feature
         | 
| 453 | 
            -
            - features/generator.feature
         | 
| 454 | 
            -
            - features/helpers_auto_stylesheet_link_tag.feature
         | 
| 455 | 
            -
            - features/helpers_page_classes.feature
         | 
| 456 | 
            -
            - features/less-css.feature
         | 
| 457 | 
            -
            - features/minify_css.feature
         | 
| 458 | 
            -
            - features/minify_javascript.feature
         | 
| 459 | 
            -
            - features/padrino_helpers.feature
         | 
| 460 | 
            -
            - features/page_alias_and_layouts.feature
         | 
| 461 | 
            -
            - features/scss-support.feature
         | 
| 462 | 
            -
            - features/step_definitions/asset_host_steps.rb
         | 
| 463 | 
            -
            - features/step_definitions/builder_steps.rb
         | 
| 464 | 
            -
            - features/step_definitions/env.rb
         | 
| 465 | 
            -
            - features/step_definitions/generator_steps.rb
         | 
| 466 | 
            -
            - features/step_definitions/middleman_steps.rb
         | 
| 467 | 
            -
            - features/step_definitions/page_layout_steps.rb
         | 
| 468 | 
            -
            - features/w_asset_host.feature
         | 
| 469 | 
            -
            - features/x_automatic_image_sizes.feature
         | 
| 470 | 
            -
            - features/y_cache_buster.feature
         | 
| 471 | 
            -
            - features/z_relative_assets.feature
         | 
| 472 | 
            -
            - fixtures/test-app/config.rb
         | 
| 473 | 
            -
            - fixtures/test-app/public/images/blank.gif
         | 
| 474 | 
            -
            - fixtures/test-app/public/static.html
         | 
| 475 | 
            -
            - fixtures/test-app/public/stylesheets/auto-css.css
         | 
| 476 | 
            -
            - fixtures/test-app/public/stylesheets/static.css
         | 
| 477 | 
            -
            - fixtures/test-app/public/stylesheets/sub1/auto-css.css
         | 
| 478 | 
            -
            - fixtures/test-app/public/stylesheets/sub1/sub2/auto-css.css
         | 
| 479 | 
            -
            - fixtures/test-app/views/_partial.haml
         | 
| 480 | 
            -
            - fixtures/test-app/views/asset_host.html.haml
         | 
| 481 | 
            -
            - fixtures/test-app/views/auto-css.html.haml
         | 
| 482 | 
            -
            - fixtures/test-app/views/auto-image-sizes.html.haml
         | 
| 483 | 
            -
            - fixtures/test-app/views/cache-buster.html.haml
         | 
| 484 | 
            -
            - fixtures/test-app/views/custom-layout.html.haml
         | 
| 485 | 
            -
            - fixtures/test-app/views/index.html.haml
         | 
| 486 | 
            -
            - fixtures/test-app/views/inline-css.html.haml
         | 
| 487 | 
            -
            - fixtures/test-app/views/inline-js.html.haml
         | 
| 488 | 
            -
            - fixtures/test-app/views/javascripts/coffee_test.js.coffee
         | 
| 489 | 
            -
            - fixtures/test-app/views/layout.haml
         | 
| 490 | 
            -
            - fixtures/test-app/views/layouts/custom.haml
         | 
| 491 | 
            -
            - fixtures/test-app/views/padrino_test.html.haml
         | 
| 492 | 
            -
            - fixtures/test-app/views/page-classes.html.haml
         | 
| 493 | 
            -
            - fixtures/test-app/views/services/index.html.haml
         | 
| 494 | 
            -
            - fixtures/test-app/views/stylesheets/asset_host.css.sass
         | 
| 495 | 
            -
            - fixtures/test-app/views/stylesheets/relative_assets.css.sass
         | 
| 496 | 
            -
            - fixtures/test-app/views/stylesheets/site.css.sass
         | 
| 497 | 
            -
            - fixtures/test-app/views/stylesheets/site_scss.css.scss
         | 
| 498 | 
            -
            - fixtures/test-app/views/stylesheets/test_less.css.less
         | 
| 450 | 
            +
            test_files: []
         | 
| 451 | 
            +
             |