do some stuff idk

master
knotteye 2021-01-08 11:06:38 -06:00
parent c8aa41d626
commit 2dd0c6467d
1 changed files with 2 additions and 2 deletions

View File

@ -44,10 +44,10 @@ index = Base
Dir.entries("articles").select{ |i| i != "." && i != ".." }.each do |article|
if article[article.size-3, article.size] == ".md"
File.write Path.new("dist", article[0,article.size-3]+".html"), render_file("articles/"+article)
index += "<h4><a href=\"/"+article[0,article.size-3]+"\"/>"+article[0,article.size-3]+"</a></h4>\n"
index += "<h3><a href=\"/"+article[0,article.size-3]+".html\"/>"+article[0,article.size-3].gsub("-", " ")+"</a></h3>\n"
else
File.write Path.new("dist", article+".html"), render_file("articles/"+article)
index += "<h4><a href=\"/"+article+"\"/>"+article+"</a></h4>\n"
index += "<h3><a href=\"/"+article+".html\"/>"+article.gsub("-", " ")+"</a></h3>\n"
end
end
File.write Path["dist/index.html"], index+"</body></html>"