From e17ad22ee27863dd1ef8d37916f87f814a15ea5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Guillaume=20Perr=C3=A9al?= <guillaume.perreal@inrae.fr> Date: Tue, 5 May 2020 10:50:47 +0200 Subject: [PATCH] =?UTF-8?q?Ne=20retraite=20que=20les=20fichiers=20modifi?= =?UTF-8?q?=C3=A9d=20en=20mode=20dev.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sauf les PDF, parce qu'on ne piste pas les dépendences. --- gulpfile.esm.js | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/gulpfile.esm.js b/gulpfile.esm.js index 036639e..7551cce 100644 --- a/gulpfile.esm.js +++ b/gulpfile.esm.js @@ -1,4 +1,4 @@ -import { dest, parallel, series, src, watch } from "gulp"; +import { dest, lastRun, parallel, series, src, watch } from "gulp"; import del from "del"; import drawio from "./lib/drawio"; import index from "./lib/index"; @@ -19,10 +19,17 @@ const PDF_GLOB = `${DEST_DIR}/**/index.html`; export const clean = () => del(`${DEST_DIR}/**`, { force: true }); -export const assets = () => src(ASSET_GLOB).pipe(dest(DEST_DIR)); +export const assets = () => + src(ASSET_GLOB, { since: lastRun(assets) }).pipe(dest(DEST_DIR)); export const prez = () => - src(PREZ_GLOB).pipe(index()).pipe(pandoc()).pipe(dest(DEST_DIR)); -export const graphs = () => src(GRAPH_GLOB).pipe(drawio()).pipe(dest(DEST_DIR)); + src(PREZ_GLOB, { since: lastRun(prez) }) + .pipe(index()) + .pipe(pandoc()) + .pipe(dest(DEST_DIR)); +export const graphs = () => + src(GRAPH_GLOB, { since: lastRun(graphs) }) + .pipe(drawio()) + .pipe(dest(DEST_DIR)); export const pdf = () => src(PDF_GLOB).pipe(wkhtmltopdf()).pipe(dest(DEST_DIR)); export const build = series(clean, parallel(assets, prez, graphs), pdf); -- GitLab