lib/nanoc/cli/commands/create-site.rb in nanoc-4.0.0 vs lib/nanoc/cli/commands/create-site.rb in nanoc-4.0.1
- old
+ new
@@ -288,12 +288,14 @@
end
path = arguments[0]
# Check whether site exists
if File.exist?(path) && (!File.directory?(path) || !(Dir.entries(path) - %w(. ..)).empty?) && !options[:force]
- raise Nanoc::Int::Errors::GenericTrivial,
+ raise(
+ Nanoc::Int::Errors::GenericTrivial,
"The site was not created because '#{path}' already exists. " \
- 'Re-run the command using --force to create the site anyway.'
+ 'Re-run the command using --force to create the site anyway.',
+ )
end
# Setup notifications
Nanoc::Int::NotificationCenter.on(:file_created) do |file_path|
Nanoc::CLI::Logger.instance.file(:high, :create, file_path)