Sha256: 52efd73dc3b0750ac14cd1a3ef78234b1ae0ec733ee0d2645287e3dcab7625e1
Contents?: true
Size: 749 Bytes
Versions: 4
Compression:
Stored size: 749 Bytes
Contents
module Moft class Command def self.globs(source, destination) Dir.chdir(source) do dirs = Dir['*'].select { |x| File.directory?(x) } dirs -= [destination, File.expand_path(destination), File.basename(destination)] dirs = dirs.map { |x| "#{x}/**/*" } dirs += ['*'] end end # Static: Run Site#process and catch errors # # site - the Moft::Site object # # Returns nothing def self.process_site(site) site.process rescue Moft::FatalException => e puts Moft::Logger.error "ERROR:", "YOUR SITE COULD NOT BE BUILT:" Moft::Logger.error "", "------------------------------------" Moft::Logger.error "", e.message exit(1) end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
moft-1.0.2.1 | lib/moft/command.rb |
moft-1.0.2 | lib/moft/command.rb |
moft-1.0.1 | lib/moft/command.rb |
moft-1.0.0 | lib/moft/command.rb |