-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
stand.rb
44 lines (36 loc) · 1.13 KB
/
stand.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# typed: false
# frozen_string_literal: true
lib = File.expand_path('lib', __dir__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
require 'date'
require 'himekuri'
require 'sinatra'
require 'sinatra/reloader'
require 'version'
require 'zella'
# class katana is mumei and slogan
class Katana
attr_accessor :mumei, :slogan
def initialize(mumei, slogan)
@mumei = mumei
@slogan = slogan
end
end
get '/' do
File.open("#{File.dirname(__FILE__)}/web/rss.xml") do |f|
@xml = f.read + "\n"
end
@es_xml = (@xml).gsub(/\R/, "<br>")
@rss_kan = '[ 最近の投稿日を表示 ]'
@kanban = '[ これより、30タイトル程ずつ履歴表示します ]'
@ruby = ('Ruby_VERSION : ' + RUBY_VERSION + ' ' + 'Sinatra_VERSION : ' + Sinatra::VERSION)
@himekuri = HimekuriClass.new.himekuri
@reiwa = HimekuriClass.new.reiwa
@year = DateTime.now.year
@wahugetsu = HimekuriClass.new.wahugetsu_web
@zella = Zella.formula
@takkii = ' Takayuki Kamiyama All Rights Reserved. '
@saya = Katana.new('Designed by NyaSoCom', 'Not Yet Another Software design of Computer')
@nyasocom_version = NYASOCOM::VERSION
erb :index
end