Class: S3Website::Paths

Inherits:
Object
  • Object
show all
Defined in:
lib/s3_website/paths.rb

Class Method Summary collapse

Class Method Details

.infer_site_path(candidate_path, pwd = Dir.pwd) ⇒ Object



7
8
9
10
11
12
13
14
15
16
# File 'lib/s3_website/paths.rb', line 7

def self.infer_site_path(candidate_path, pwd = Dir.pwd)
  if candidate_path == 'infer automatically'
    infer_automatically pwd
  else
    candidate_path_if_exists candidate_path
  end
rescue NoWebsiteDirectoryFound => e
  puts e.message
  exit 1
end

.site_pathsObject



3
4
5
# File 'lib/s3_website/paths.rb', line 3

def self.site_paths
  [Nanoc::SITE_PATH, Jekyll::SITE_PATH]
end