From 0997667a1e9751372c7640b159b51e562c662180 Mon Sep 17 00:00:00 2001 From: tomoya yoshida Date: Wed, 14 May 2025 12:05:19 +0900 Subject: [PATCH 1/2] =?UTF-8?q?pandoc2review=E5=88=A9=E7=94=A8=E6=99=82?= =?UTF-8?q?=E3=81=AE=E3=82=A8=E3=83=A9=E3=83=BC=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit pandoc2review利用の設定でcontentdirを_refilesにするとpreprocessでreファイルが 存在しないためエラーが発生するため、preprocessではなにもせず、 pandoc2review処理時にpreprocをするように修正 --- Gruntfile.js | 2 +- articles/lib/tasks/z01_pandoc2review.rake | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Gruntfile.js b/Gruntfile.js index 4e2e6088..8efde0a4 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -40,7 +40,7 @@ module.exports = grunt => { cwd: articles, } }, - command: `${reviewPreproc} -r --tabwidth=2 ${reviewContentDir}/*.re` + command: `${reviewContentDir === '_refiles' ? "echo 'skip preprocess'" : `${reviewPreproc} -r --tabwidth=2 ${reviewContentDir}/*.re`}` }, compile2text: { options: { diff --git a/articles/lib/tasks/z01_pandoc2review.rake b/articles/lib/tasks/z01_pandoc2review.rake index ff7b0243..83ba9dcd 100644 --- a/articles/lib/tasks/z01_pandoc2review.rake +++ b/articles/lib/tasks/z01_pandoc2review.rake @@ -28,6 +28,7 @@ def make_mdre(ch, p2r, path) elsif File.exist?(ch.sub(/\.re\Z/, '.md')) # md file system("#{p2r} #{ch.sub(/\.re\Z/, '.md')} > #{path}/#{ch}") end + sh "review-preproc -r --tabwidth=2 #{File.join(path, ch)}" end def yaml_load_file_compatible(file) From da5b8e6d65ca3a2649f97336da1428b9addd8774 Mon Sep 17 00:00:00 2001 From: tomoya yoshida Date: Wed, 14 May 2025 12:13:58 +0900 Subject: [PATCH 2/2] =?UTF-8?q?articles/=5Frefiles=E3=83=87=E3=82=A3?= =?UTF-8?q?=E3=83=AC=E3=82=AF=E3=83=88=E3=83=AA=E3=82=92git=E5=AF=BE?= =?UTF-8?q?=E8=B1=A1=E5=A4=96=E3=81=AB=E3=81=99=E3=82=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 1b47766c..cf0feff8 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ articles/*.html # articles/*.md articles/*.xml articles/*.txt +articles/_refiles/ \ No newline at end of file