X-Git-Url: https://iankelling.org/git/?p=iankelling.org;a=blobdiff_plain;f=build.rb;h=b1a3411b75c98b8bb86a939508373582c7b63327;hp=4025eefa3b452e36d6ee5910e41dd29ea10bfdd3;hb=34165b546bf7469aeb0e5bd6fdf3df6debdbbe3d;hpb=3c09af9cc854c716d9f772d1c8c1e568cacc92b9 diff --git a/build.rb b/build.rb index 4025eef..b1a3411 100755 --- a/build.rb +++ b/build.rb @@ -30,6 +30,7 @@ blog_list = [] # table data FileUtils.mkdir_p('../proposed-comments') FileUtils.chmod(0777, '../proposed-comments') FileUtils.rm Dir.glob('blog/*') +FileUtils.rm Dir.glob('css/*') $db = db_init # date has no type affinity, since floating point (REAL) doesn't @@ -79,7 +80,7 @@ EOF fskel('index.html', DN, File.read('../index.html')) stdpage('blog', < + EOF @@ -88,4 +89,18 @@ if File.exists? ('../resume.md') stdpage('resume', md_to_html(File.read('../resume.md'))) end -stdpage('favorite-stuff', File.read('../favorite-stuff.html')) +stdpage('favorite-things', File.read('../favorite-things.html')) + +# we could use ruby native stuff here, but this was +# better documented so meh. +# Force because it's cache is not perfect, it definitely misses renamed symlinks. + +ret = 0 +["main", "gitweb-site"].each do |basename| + cmd = "scss --force --cache-location ../.sass-cache" + unless system("#{cmd} ../css/#{basename}.scss css/#{basename}.css") + ret = 1 + end +end + +exit ret