From 6f348e240e3c539acbd17acf1967604722228540 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Tue, 28 Jun 2022 15:25:17 +0200 Subject: [PATCH] :zap: Make paths OS-agnostic --- gulpfile.js | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 5cab748..831c707 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -1,11 +1,16 @@ +const path = require('path'); const { task, src, dest } = require('gulp'); task('build:icons', copyIcons); function copyIcons() { - src('nodes/**/*.{png,svg}').pipe(dest('dist/nodes')); + const nodeSource = path.resolve('nodes', '**', '*.{png,svg}'); + const nodeDestination = path.resolve('dist', 'nodes'); - return src('credentials/**/*.{png,svg}').pipe(dest('dist/credentials')); + src(nodeSource).pipe(dest(nodeDestination)); + + const credSource = path.resolve('credentials', '**', '*.{png,svg}'); + const credDestination = path.resolve('dist', 'credentials'); + + return src(credSource).pipe(dest(credDestination)); } - -// TODO: Add i18n to pipeline