mirror of https://github.com/Calamitous/iris.git
Remove config file fxality until I have something to put in there
This commit is contained in:
parent
0b4dfa6a7f
commit
4631157712
11
iris.rb
11
iris.rb
|
@ -2,7 +2,6 @@
|
|||
|
||||
# MVP:
|
||||
# -----
|
||||
# TODO: Remove user config?
|
||||
# TODO: Validate author with file owner
|
||||
# TODO: Add optional title for topics
|
||||
# TODO: Don't crash when names are cattywumpus
|
||||
|
@ -55,7 +54,6 @@ require 'readline'
|
|||
|
||||
class Config
|
||||
VERSION = '1.0.0'
|
||||
CONFIG_FILE = "#{ENV['HOME']}/.iris.config.json"
|
||||
MESSAGE_FILE = "#{ENV['HOME']}/.iris.messages"
|
||||
HISTORY_FILE = "#{ENV['HOME']}/.iris.history"
|
||||
|
||||
|
@ -63,15 +61,6 @@ class Config
|
|||
HOSTNAME = `hostname -d`.chomp
|
||||
AUTHOR = "#{USER}@#{HOSTNAME}"
|
||||
|
||||
def self.get(filepath = CONFIG_FILE)
|
||||
return @@loaded_config if @@loaded_config
|
||||
if !File.exists?(filepath)
|
||||
File.write(filepath, '{}')
|
||||
return @@loaded_config = {}
|
||||
end
|
||||
return @@loaded_config = JSON.load(filepath)
|
||||
end
|
||||
|
||||
def self.find_files
|
||||
@@message_corpus ||= (`ls /home/**/.iris.messages`).split("\n")
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue