Class: Madness::Commands::Theme

Inherits:
Base
  • Object
show all
Defined in:
lib/madness/commands/theme.rb

Instance Method Summary collapse

Methods inherited from Base

#config

Instance Method Details

#colors_commandObject



26
27
28
# File 'lib/madness/commands/theme.rb', line 26

def colors_command
  copy_file 'app/styles/_variables.scss', 'css/colors.css'
end

#css_commandObject



22
23
24
# File 'lib/madness/commands/theme.rb', line 22

def css_command
  copy_file 'app/public/css/main.css', 'css/main.css'
end

#full_commandObject

Raises:



15
16
17
18
19
20
# File 'lib/madness/commands/theme.rb', line 15

def full_command
  raise InitError, "Directory #{theme_path} already exists" if Dir.exist? theme_path

  FileUtils.cp_r File.expand_path('../../../app', __dir__), theme_path
  say "Created g`#{theme_path}` theme folder"
end