From e5dee1e72e102d7afbd5d8aa6b6f7bc5633c263a Mon Sep 17 00:00:00 2001 From: Kitaiti Makoto Date: Sun, 20 Dec 2020 14:02:06 +0900 Subject: [PATCH] Reset build tasks --- Rakefile | 57 +++++++++++++++++++++++++++++++++++++++-------------- crowdin.yml | 2 +- 2 files changed, 43 insertions(+), 16 deletions(-) diff --git a/Rakefile b/Rakefile index b08f87b..32096fa 100644 --- a/Rakefile +++ b/Rakefile @@ -1,20 +1,32 @@ require "pathname" -BUILD_DIR = "build" -TRANS_DIR = "trans" -LOCALE_DIR = "locale" +BUILD_DIR = Pathname("build") +LOCALE_DIR = Pathname("trans") +TRANS_DIR = Pathname("translate") +PSEUDO_LANG = "ach" -task :default => [:build_trans, "crowdin:upload", :build_site] +CROWDIN_SNIPPET = < + var _jipt = []; + _jipt.push(['project', 'plume-docs']); + _jipt.push(['escape', function() { + window.location.href = 'https://joinplu.me'; + }]); + + +EOS + +class Pathname + alias to_str to_s +end desc "Build site" -multitask :build_site => [:build_base, "crowdin:download"] do - Pathname.glob("#{LOCALE_DIR}/**/*.html").select(&:file?).each do |path| - content = path.read - content.sub! /