Module: Middleman::Deploy

Defined in:
lib/middleman-deploy/pkg-info.rb,
lib/middleman-deploy/extension.rb

Defined Under Namespace

Modules: Helpers Classes: Options

Constant Summary collapse

PACKAGE =
"middleman-deploy"
VERSION =
"0.1.3"
TAGLINE =
"Deploy a middleman built site over rsync, ftp, sftp, or git (e.g. gh-pages on github)."

Class Method Summary collapse

Class Method Details

.optionsObject



12
13
14
# File 'lib/middleman-deploy/extension.rb', line 12

def options
  @@options
end

.registered(app, options_hash = {}) {|options| ... } ⇒ Object Also known as: included

Yields:



16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# File 'lib/middleman-deploy/extension.rb', line 16

def registered(app, options_hash={}, &block)
  options = Options.new(options_hash)
  yield options if block_given?

  # Default options for the rsync method.
  options.port ||= 22
  options.clean ||= false

  # Default options for the git method.
  options.remote ||= "origin"
  options.branch ||= "gh-pages"

  options.build_before ||= false

  @@options = options

  app.send :include, Helpers
end