Class: GitBlog::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/git-blog/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#blog_pathObject

Returns the value of attribute blog_path.



6
7
8
# File 'lib/git-blog/configuration.rb', line 6

def blog_path
  @blog_path
end

#template_contentObject

Returns the value of attribute template_content.



7
8
9
# File 'lib/git-blog/configuration.rb', line 7

def template_content
  @template_content
end

Instance Method Details

#readObject



9
10
11
12
# File 'lib/git-blog/configuration.rb', line 9

def read
  dict = Storage::config_dict
  @blog_path = dict["blog-path"]
end

#writeObject



14
15
16
17
# File 'lib/git-blog/configuration.rb', line 14

def write
  dict = { "blog-path" => @blog_path }
  Storage::save_config_dict dict
end