Class: ThemeJuice::Tasks::Landrush

Inherits:
Entry show all
Defined in:
lib/theme-juice/tasks/landrush.rb

Instance Attribute Summary

Attributes inherited from Entry

#entry

Attributes inherited from ThemeJuice::Task

#tasks

Instance Method Summary collapse

Methods inherited from ThemeJuice::Task

#runner

Constructor Details

#initialize(opts = {}) ⇒ Landrush

Returns a new instance of Landrush.



7
8
9
10
11
12
13
14
15
16
# File 'lib/theme-juice/tasks/landrush.rb', line 7

def initialize(opts = {})
  super

  @entry = {
    :project => "landrush",
    :file    => "#{@env.vm_path}/Customfile",
    :name    => "landrush",
    :id      => "LR"
  }
end

Instance Method Details

#executeObject



18
19
20
21
22
23
24
25
26
27
# File 'lib/theme-juice/tasks/landrush.rb', line 18

def execute
  return if @env.no_landrush

  create_entry_file
  create_entry do
%Q{config.landrush.enabled = true
config.landrush.tld = 'dev'
config.landrush.host 'graft.dev', '#{@env.vm_ip}'}
  end
end

#unexecuteObject



29
30
31
# File 'lib/theme-juice/tasks/landrush.rb', line 29

def unexecute
  remove_entry
end