⚡ Make paths OS-agnostic
This commit is contained in:
parent
e2b4595066
commit
6f348e240e
1 changed files with 9 additions and 4 deletions
13
gulpfile.js
13
gulpfile.js
|
|
@ -1,11 +1,16 @@
|
||||||
|
const path = require('path');
|
||||||
const { task, src, dest } = require('gulp');
|
const { task, src, dest } = require('gulp');
|
||||||
|
|
||||||
task('build:icons', copyIcons);
|
task('build:icons', copyIcons);
|
||||||
|
|
||||||
function 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
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue