TrailingWhitespace 'cop' fix

This commit is contained in:
Karl Freeman 2013-12-28 18:14:15 +00:00
parent bf327c17b7
commit a31aa5d8be
13 changed files with 20 additions and 20 deletions

View file

@ -8,7 +8,7 @@ module Middleman::Cli
check_unknown_options!
namespace :console
desc 'console [options]', 'Start an interactive console in the context of your Middleman application'
method_option :environment,
:aliases => '-e',

View file

@ -11,13 +11,13 @@ module Middleman::Cli
# Required path for the new project to be generated
argument :name, :type => :string
# Template files are relative to this file
# @return [String]
def self.source_root
File.join(File.dirname(__FILE__), '..', 'templates', 'extension')
end
desc 'extension [options]', 'Create Middleman extension scaffold NAME'
# The extension task

View file

@ -1,6 +1,6 @@
module Middleman
module Configuration
# Access to a global configuration manager for the whole Middleman project,
# Access to a global configuration manager for the whole Middleman project,
# plus backwards compatibility mechanisms for older Middleman projects.
module Global
def self.included(app)

View file

@ -181,7 +181,7 @@ module Middleman
def respond_to?(method, include_private = false)
super || has_key?(method)
end
# Make DataStore act like a hash. Return requested data, or
# nil if data does not exist
#

View file

@ -48,7 +48,7 @@ module Middleman::CoreExtensions
{ :options => data, :page => ::Middleman::Util.recursively_enhance(fmdata).freeze }
end
end
module ResourceInstanceMethods
def ignored?
if !proxy? && raw_data[:ignored] == true
@ -178,7 +178,7 @@ module Middleman::CoreExtensions
return [data, nil] if !app.files.exists?(full_path) || ::Middleman::Util.binary?(full_path)
content = File.read(full_path)
begin
if content =~ /\A.*coding:/
lines = content.split(/\n/)

View file

@ -244,7 +244,7 @@ module Middleman
# Store last engine for later (could be inside nested renders)
context.current_engine, engine_was = engine, context.current_engine
# Save current buffer for later
@_out_buf, _buf_was = '', @_out_buf

View file

@ -40,12 +40,12 @@ module Middleman
def initialize(*args, &block)
super
if @options.has_key?(:context)
@context = @options[:context]
end
end
# Define the expected syntax for the template
# @return [Symbol]
def syntax
@ -73,15 +73,15 @@ module Middleman
# @return [Hash]
def sass_options
more_opts = { :filename => eval_file, :line => line, :syntax => syntax }
if @context.is_a?(::Middleman::Application) && file
location_of_sass_file = @context.source_dir
parts = basename.split('.')
parts.pop
more_opts[:css_filename] = File.join(location_of_sass_file, @context.config[:css_dir], parts.join('.'))
end
options.merge(more_opts)
end
end

View file

@ -23,7 +23,7 @@ module Middleman
:generator => ::Temple::Generators::RailsOutputBuffer,
:disable_escape => true
)
app.after_configuration do
context_hack = {
:context => self

View file

@ -2,7 +2,7 @@ require 'active_support/core_ext/object/inclusion'
module Middleman
module Sitemap
# Code adapted from https://github.com/ralph/document_mapper/
module Queryable
OPERATOR_MAPPING = {
@ -146,7 +146,7 @@ class Symbol
end
OPERATORS
end
unless method_defined?(:"<=>")
def <=>(other)
self.to_s <=> other.to_s

View file

@ -26,7 +26,7 @@ class Middleman::Extensions::AssetHost < ::Middleman::Extension
app.config[:asset_host] || options[:host]
end
helpers do
helpers do
# Override default asset url helper to include asset hosts
#
# @param [String] path

View file

@ -8,7 +8,7 @@ class Middleman::Extensions::AutomaticAltTags < ::Middleman::Extension
helpers do
# Override default image_tag helper to automatically insert alt tag
# containing image name.
def image_tag(path)
if !path.include?('://')
params[:alt] ||= ''

View file

@ -18,7 +18,7 @@ class Middleman::Extensions::CacheBuster < ::Middleman::Extension
end if app.respond_to?(:compass_config)
end
helpers do
helpers do
# asset_url override if we're using cache busting
# @param [String] path
# @param [String] prefix

View file

@ -10,7 +10,7 @@ class Middleman::Templates::Smacss < Middleman::Templates::Base
class_option 'images_dir',
:default => 'images',
:desc => 'The path to the image files'
# Template files are relative to this file
# @return [String]
def self.source_root