lib/airbrake/cli/options.rb in airbrake-3.1.10 vs lib/airbrake/cli/options.rb in airbrake-3.1.11
- old
+ new
@@ -1,8 +1,8 @@
class Options
- ATTRIBUTES = [:error, :message, :api_key, :host, :port, :auth_token, :name, :account, :rails_env]
+ ATTRIBUTES = [:error, :message, :api_key, :host, :port, :auth_token, :name, :account, :rails_env, :scm_revision]
ATTRIBUTES.each do |attribute|
attr_reader attribute
end
@@ -25,9 +25,10 @@
self.port = opts.delete("-p") || opts.delete("--port") || config_from_file.port
self.auth_token = opts.delete("-t") || opts.delete("--auth-token") || ENV["AIRBRAKE_AUTH_TOKEN"]
self.name = opts.delete("-n") || opts.delete("--name")
self.account = opts.delete("-a") || opts.delete("--account") || ENV["AIRBRAKE_ACCOUNT"]
self.rails_env = opts.delete("-E") || opts.delete("--rails-env") || ENV["RAILS_ENV"] || "production"
+ self.scm_revision = opts.delete("-r") || opts.delete("--scm-revision")
opts
end
# Fallback to read from the initializer
def config_from_file