forked from exceptional/exceptional
-
Notifications
You must be signed in to change notification settings - Fork 1
/
install.rb
19 lines (16 loc) · 815 Bytes
/
install.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# This is the post install hook for when Exceptional is installed as a plugin.
require 'ftools'
# puts IO.read(File.join(File.dirname(__FILE__), 'README'))
config_file = File.expand_path("#{File.dirname(__FILE__)}/../../../config/exceptional.yml")
example_config_file = "#{File.dirname(__FILE__)}/exceptional.yml"
if File::exists? config_file
puts "Exceptional config file already exists. Please ensure it is up-to-date with the current format."
puts "See #{example_config_file}"
else
puts "Installing default Exceptional config."
puts " From #{example_config_file}"
puts "For exceptional to work you need to configure your API key."
puts " See #{example_config_file}"
puts "If you don't have an API key, get one at http://getexceptional.com/."
File.copy example_config_file, config_file
end