lib/Charu/Config.rb in Charu-0.0.12 vs lib/Charu/Config.rb in Charu-0.0.16

- old
+ new

@@ -1,58 +1,66 @@ -# -*- encoding: utf-8 -*- +# -*- encoding: utf-8 -*- config = "" config = '# -*- encoding: utf-8 -*- module Charu class Config - attr_accessor :home_title, :top_home_page, :home_category, :home_description, :css_theme_path, :private_category - attr_accessor :change_log_path, :article_size, :www_html_out_path, :www_html_out_path_private, :public_category + attr_accessor :home_title, :top_home_page, :home_category, :css_theme_path, :private_category + attr_accessor :change_log_path, :article_size, :www_html_out_path, :www_html_out_path_private, :public_category, :private_mode attr_accessor :ftp_server, :ftp_port, :ftp_user, :ftp_pass - attr_accessor :wget_path + attr_accessor :wget_path def initialize() # ホームページタイトル @home_title = "TestPage" # ホームページトップ - @top_home_page = "http://hoge.com/hoge/index.html" + @top_home_page = "http://hoge.com/hoge/" # ホームページカテゴリー - @home_category = ["Ruby", "Python", "Java", "c++", "Ruby_on_Rails", "JavaSciript", "LIPS"] + @home_category = ["Ruby", "Python", "Java", "c++", "Ruby on Rails", "JavaSciript", "LIPS"] # ホームページのdescription - @home_description = "日々勉強中" + @home_description = ["", ""] # CSS Path @css_theme_path = "./css/" - # プライベートカテゴリー + # プライベートカテゴリー @private_category = ["Private", "P", "★", "2ch", "5ch", "PS", "Life"] - # パブリックカテゴリー + # パブリックカテゴリー @public_category = ["Public"] - + # Change_Log_path @change_log_path = "./../ChangeLog" # 一度に表示する記事数 @article_size = 50 - # htmlの作成先 - @www_html_out_path = "./www/" + # htmlの作成先 パブリック + @www_html_out_path = "./www/Public/" # htmlの作成先 プライベート - @www_html_out_path_private = "./Private/" + @www_html_out_path_private = "./www/Private/" + # プライベートを出力するか?true or false + @private_mode = true + # FTPの設定 @ftp_server = "" @ftp_port = "21" @ftp_user = "" @ftp_pass = "" # Wgetのパス @wget_path = "" - + + end + + def home_description() + i = rand(@home_description.size) + return @home_description[i] end end end '