Commit e17ad22e authored by Guillaume Perréal's avatar Guillaume Perréal
Browse files

Ne retraite que les fichiers modifiéd en mode dev.

Sauf les PDF, parce qu'on ne piste pas les dépendences.
No related merge requests found
Showing with 11 additions and 4 deletions
+11 -4
import { dest, parallel, series, src, watch } from "gulp"; import { dest, lastRun, parallel, series, src, watch } from "gulp";
import del from "del"; import del from "del";
import drawio from "./lib/drawio"; import drawio from "./lib/drawio";
import index from "./lib/index"; import index from "./lib/index";
...@@ -19,10 +19,17 @@ const PDF_GLOB = `${DEST_DIR}/**/index.html`; ...@@ -19,10 +19,17 @@ const PDF_GLOB = `${DEST_DIR}/**/index.html`;
export const clean = () => del(`${DEST_DIR}/**`, { force: true }); 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 = () => export const prez = () =>
src(PREZ_GLOB).pipe(index()).pipe(pandoc()).pipe(dest(DEST_DIR)); src(PREZ_GLOB, { since: lastRun(prez) })
export const graphs = () => src(GRAPH_GLOB).pipe(drawio()).pipe(dest(DEST_DIR)); .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 pdf = () => src(PDF_GLOB).pipe(wkhtmltopdf()).pipe(dest(DEST_DIR));
export const build = series(clean, parallel(assets, prez, graphs), pdf); export const build = series(clean, parallel(assets, prez, graphs), pdf);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment