Class: Comet::Rules::Clean

Inherits:
Object
  • Object
show all
Defined in:
lib/comet/rules/clean.rb

Instance Method Summary collapse

Constructor Details

#initialize(folder) ⇒ Clean

Returns a new instance of Clean.



4
5
6
# File 'lib/comet/rules/clean.rb', line 4

def initialize(folder)
  @folder = folder
end

Instance Method Details

#commandsObject



24
25
26
# File 'lib/comet/rules/clean.rb', line 24

def commands
  { COMET_RM: 'rm' }
end

#contentsObject



12
13
14
15
16
17
18
# File 'lib/comet/rules/clean.rb', line 12

def contents
  [
    ".PHONY: #{target}",
    "#{target}:",
    "\t$(COMET_RM) -rf #{@folder}"
  ]
end

#rulesObject



20
21
22
# File 'lib/comet/rules/clean.rb', line 20

def rules
  []
end

#targetObject



8
9
10
# File 'lib/comet/rules/clean.rb', line 8

def target
  'clean'
end