tonka 0.0.2b1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/tonka.rb +21 -21
- metadata +4 -4
data/lib/tonka.rb
CHANGED
@@ -87,7 +87,7 @@ class Tonka::HTML
|
|
87
87
|
body = options[3] || ""
|
88
88
|
jquery = true if options[2] == "-jquery"
|
89
89
|
index_html = File.new("#{site_name}/index.html","w")
|
90
|
-
@layout = "<!DOCTYPE html>\n<html>\n<head>\n<title>#{site_name}</title>\n<link rel=\"stylesheet\" type=\"text/css\" href=\"stylesheets/style.css\"
|
90
|
+
@layout = "<!DOCTYPE html>\n<html>\n<head>\n<title>#{site_name}</title>\n<link rel=\"stylesheet\" type=\"text/css\" href=\"stylesheets/style.css\" />\n<script type=\"text/javascript\" src=\"javascripts/scripts.js\"></script>#{ "\n<script type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js\"></script>" if jquery == true }\n</head>\n<body>\n#{ body+"\n" }\</body>\n</html>"
|
91
91
|
index_html.puts @layout
|
92
92
|
index_html.close
|
93
93
|
puts "\t\tbuilt ".green+"#{site_name}/index.html"
|
@@ -121,24 +121,24 @@ class Tonka::JS
|
|
121
121
|
end
|
122
122
|
|
123
123
|
class String
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
124
|
+
# text colorization
|
125
|
+
def colorize(color_code)
|
126
|
+
"\e[#{color_code}m#{self}\e[0m"
|
127
|
+
end
|
128
|
+
|
129
|
+
def red
|
130
|
+
colorize(31)
|
131
|
+
end
|
132
|
+
|
133
|
+
def green
|
134
|
+
colorize(32)
|
135
|
+
end
|
136
|
+
|
137
|
+
def yellow
|
138
|
+
colorize(33)
|
139
|
+
end
|
140
|
+
|
141
|
+
def pink
|
142
|
+
colorize(35)
|
143
|
+
end
|
144
144
|
end
|
metadata
CHANGED
@@ -1,8 +1,8 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tonka
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
5
|
-
prerelease:
|
4
|
+
version: 0.0.2
|
5
|
+
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Omar Delarosa
|
@@ -36,9 +36,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
36
36
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
37
37
|
none: false
|
38
38
|
requirements:
|
39
|
-
- - ! '
|
39
|
+
- - ! '>='
|
40
40
|
- !ruby/object:Gem::Version
|
41
|
-
version:
|
41
|
+
version: '0'
|
42
42
|
requirements: []
|
43
43
|
rubyforge_project:
|
44
44
|
rubygems_version: 1.8.25
|