Class: T1k::Commands::Init

Inherits:
Object
  • Object
show all
Defined in:
lib/t1k/commands/init.rb

Class Method Summary collapse

Class Method Details

.create_T1000_fileObject



19
20
21
22
23
24
# File 'lib/t1k/commands/init.rb', line 19

def self.create_T1000_file
  src  = File.join(T1k::path_to_resources, "T1000")
  dest = T1k::tthousand_path

  FileUtils.cp(src, dest)
end

.runObject



7
8
9
10
11
12
13
14
15
16
# File 'lib/t1k/commands/init.rb', line 7

def self.run
  if Validate.credentials?
    puts "There is T1000 file inside your directory. Remove it before do init.".red
    exit 1
  end

  self.create_T1000_file

  puts "Setup your T1000 file".blue
end