lib/octopolo/user_config.rb in octopolo-0.2.1 vs lib/octopolo/user_config.rb in octopolo-0.3.0
- old
+ new
@@ -2,10 +2,11 @@
class UserConfig
# config values
attr_accessor :github_user
attr_accessor :github_token
attr_accessor :full_name
+ attr_accessor :editor
attr_accessor :pivotal_token
attr_accessor :attributes # keep the whole hash
# Public: Initialize a new UserConfig instance
def initialize attributes={}
@@ -75,9 +76,16 @@
# Public: The user's name
#
# Returns a String
def full_name
@full_name || ENV["USER"]
+ end
+
+ # Public: Always use the $EDITOR when available
+ #
+ # Returns a value or false
+ def editor
+ @editor || false
end
# Public: The GitHub username
#
# If none is stored, generate it for the user.