diff options
author | pdp8 <pdp8@pdp8.info> | 2024-03-04 23:13:40 +0100 |
---|---|---|
committer | pdp8 <pdp8@pdp8.info> | 2024-03-04 23:13:40 +0100 |
commit | 0555b2cd77986d916968f1443e375fad005c8d43 (patch) | |
tree | 84112db3509f5d9b40fe41abd14fa6bc1c41303d /file.rb | |
parent | 6b40f3b54efabb740e825ba3d94b5695c2b98ede (diff) |
html.rb separated, Makefile for website generation
Diffstat (limited to 'file.rb')
-rwxr-xr-x | file.rb | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -0,0 +1,12 @@ +#!/usr/bin/env ruby +require_relative 'lib' + +path = ARGV[0] +basename = File.basename(path, File.extname(path)) +html = File.read(File.join(SNIPPETS, 'head.html')) +html += nav basename +html += "<div class='post'>" +html += File.read(path) +html += '</div>' +html += File.read(File.join(SNIPPETS, 'tail.html')) +print_html basename, html |