Skip to content

Commit b578f02

Browse files
committed
gulp automation for cleaning files
1 parent 01e72a3 commit b578f02

File tree

3 files changed

+19
-1
lines changed

3 files changed

+19
-1
lines changed

gulpfile.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
import { series } from 'gulp';
2+
import { clean } from './utils/clean';
3+
4+
export default series(
5+
6+
// Cleaning 'src','svg','es','lib' before copying SVGs from 'EOS-Icons'
7+
clean(['src','svg','es','lib'])
8+
);

package.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "Eos-Icons React npm package",
55
"main": "index.js",
66
"scripts": {
7-
"test": "echo \"Error: no test specified\" && exit 1"
7+
"generate": "gulp --require ts-node/register/transpile-only"
88
},
99
"repository": {
1010
"type": "git",
@@ -17,13 +17,17 @@
1717
},
1818
"homepage": "https://github.com/EOS-uiux-Solutions/eos-icons-react#readme",
1919
"devDependencies": {
20+
"@types/gulp": "^4.0.8",
2021
"@typescript-eslint/eslint-plugin": "^4.27.0",
2122
"@typescript-eslint/parser": "^4.27.0",
23+
"eos-icons": "^5.1.0",
2224
"eslint": "^7.28.0",
2325
"eslint-config-standard": "^16.0.3",
2426
"eslint-plugin-import": "^2.23.4",
2527
"eslint-plugin-node": "^11.1.0",
2628
"eslint-plugin-promise": "^5.1.0",
29+
"gulp": "^4.0.2",
30+
"ts-node": "^10.0.0",
2731
"typescript": "^4.3.2"
2832
},
2933
"peerDependencies": {

utils/clean.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import del from 'del';
2+
3+
export const clean = (dirs: string[]) =>
4+
function CleanDirectories() {
5+
return del(dirs);
6+
};

0 commit comments

Comments
 (0)