Skip to content

Commit

Permalink
Merge pull request #333 from BBC-News/issue319
Browse files Browse the repository at this point in the history
fix #319
  • Loading branch information
ChrisBAshton committed Nov 30, 2015
2 parents 605fbb5 + fcb75a6 commit 1bf709b
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions lib/wraith/gallery.rb
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,9 @@ def generate_gallery(with_path = "")
generate_html(@location, directories, slideshow_template, dest, with_path)

puts "Gallery generated"
check_failed_shots
failed = check_failed_shots
prompt_user_to_open_gallery dest
exit 1 if failed
end

def check_failed_shots
Expand All @@ -167,12 +169,17 @@ def check_failed_shots
end
end

exit 1
return false
else
true
end
end

def prompt_user_to_open_gallery(dest)
puts "\nView the gallery in your browser:"
puts "\t file://" + `pwd`.chomp + '/' + dest
end

class ErbBinding < OpenStruct
def get_binding
binding
Expand Down

0 comments on commit 1bf709b

Please sign in to comment.