Class: Jekyll_FTP::Error

Inherits:
Object
  • Object
show all
Defined in:
lib/jekyll-ftp/error.rb

Class Method Summary collapse

Class Method Details

.config_error(missing) ⇒ Object



7
8
9
10
11
12
13
14
15
# File 'lib/jekyll-ftp/error.rb', line 7

def self.config_error(missing)
  unless missing.empty?
    say "ERROR:".red + " Config file not set up properly."
    missing.each do |missed|
      say "  Missing:".yellow + " #{missed}"
    end
    abort
  end
end

.file_missing(filename) ⇒ Object



3
4
5
# File 'lib/jekyll-ftp/error.rb', line 3

def self.file_missing(filename)
  abort("ERROR:".red + " #{filename} does not exist.\n" + "Make sure you're in your site's root directory.".yellow)
end