File tree 5 files changed +43
-27
lines changed
5 files changed +43
-27
lines changed Original file line number Diff line number Diff line change @@ -145,14 +145,10 @@ function tag() {
145
145
execSync ( `git config --global user.name ${ process . env . GITHUB_USER_NAME } ` ) ;
146
146
execSync ( `git tag ${ version } ` ) ;
147
147
execSync (
148
- `git push https://${
149
- process . env . GITHUB_TOKEN
150
- } @github.com/vueComponent/ant-design-vue.git ${ version } :${ version } `,
148
+ `git push https://${ process . env . GITHUB_TOKEN } @github.com/vueComponent/ant-design-vue.git ${ version } :${ version } ` ,
151
149
) ;
152
150
execSync (
153
- `git push https://${
154
- process . env . GITHUB_TOKEN
155
- } @github.com/vueComponent/ant-design-vue.git master:master`,
151
+ `git push https://${ process . env . GITHUB_TOKEN } @github.com/vueComponent/ant-design-vue.git master:master` ,
156
152
) ;
157
153
console . log ( 'tagged' ) ;
158
154
}
Original file line number Diff line number Diff line change @@ -110,9 +110,7 @@ export default {
110
110
if ( settings . centerMode ) {
111
111
if ( settings . slidesToScroll > 1 && process . env . NODE_ENV !== 'production' ) {
112
112
console . warn (
113
- `slidesToScroll should be equal to 1 in centerMode, you are using ${
114
- settings . slidesToScroll
115
- } `,
113
+ `slidesToScroll should be equal to 1 in centerMode, you are using ${ settings . slidesToScroll } ` ,
116
114
) ;
117
115
}
118
116
settings . slidesToScroll = 1 ;
@@ -121,16 +119,12 @@ export default {
121
119
if ( settings . fade ) {
122
120
if ( settings . slidesToShow > 1 && process . env . NODE_ENV !== 'production' ) {
123
121
console . warn (
124
- `slidesToShow should be equal to 1 when fade is true, you're using ${
125
- settings . slidesToShow
126
- } `,
122
+ `slidesToShow should be equal to 1 when fade is true, you're using ${ settings . slidesToShow } ` ,
127
123
) ;
128
124
}
129
125
if ( settings . slidesToScroll > 1 && process . env . NODE_ENV !== 'production' ) {
130
126
console . warn (
131
- `slidesToScroll should be equal to 1 when fade is true, you're using ${
132
- settings . slidesToScroll
133
- } `,
127
+ `slidesToScroll should be equal to 1 when fade is true, you're using ${ settings . slidesToScroll } ` ,
134
128
) ;
135
129
}
136
130
settings . slidesToShow = 1 ;
Original file line number Diff line number Diff line change @@ -385,9 +385,7 @@ function processEntity(entity, wrapper) {
385
385
if ( currentEntity ) {
386
386
warning (
387
387
false ,
388
- `Conflict! value of node '${ entity . key } ' (${ value } ) has already used by node '${
389
- currentEntity . key
390
- } '.`,
388
+ `Conflict! value of node '${ entity . key } ' (${ value } ) has already used by node '${ currentEntity . key } '.` ,
391
389
) ;
392
390
}
393
391
wrapper . valueEntities [ value ] = entity ;
Original file line number Diff line number Diff line change @@ -110,12 +110,18 @@ function copyHtml() {
110
110
) ;
111
111
}
112
112
113
- gulp . task ( '_site' , done => {
114
- dist ( ( ) => {
113
+ gulp . task (
114
+ '_site' ,
115
+ gulp . series ( done => {
116
+ dist ( ( ) => {
117
+ copyHtml ( ) ;
118
+ done ( ) ;
119
+ } ) ;
120
+ } ) ,
121
+ ) ;
122
+ gulp . task (
123
+ 'copy-html' ,
124
+ gulp . series ( ( ) => {
115
125
copyHtml ( ) ;
116
- done ( ) ;
117
- } ) ;
118
- } ) ;
119
- gulp . task ( 'copy-html' , ( ) => {
120
- copyHtml ( ) ;
121
- } ) ;
126
+ } ) ,
127
+ ) ;
Original file line number Diff line number Diff line change @@ -13,6 +13,28 @@ program.on('--help', () => {
13
13
14
14
program . parse ( process . argv ) ;
15
15
16
+ function runTask ( toRun ) {
17
+ const metadata = { task : toRun } ;
18
+ // Gulp >= 4.0.0 (doesn't support events)
19
+ const taskInstance = gulp . task ( toRun ) ;
20
+ if ( taskInstance === undefined ) {
21
+ gulp . emit ( 'task_not_found' , metadata ) ;
22
+ return ;
23
+ }
24
+ const start = process . hrtime ( ) ;
25
+ gulp . emit ( 'task_start' , metadata ) ;
26
+ try {
27
+ taskInstance . apply ( gulp ) ;
28
+ metadata . hrDuration = process . hrtime ( start ) ;
29
+ gulp . emit ( 'task_stop' , metadata ) ;
30
+ gulp . emit ( 'stop' ) ;
31
+ } catch ( err ) {
32
+ err . hrDuration = process . hrtime ( start ) ;
33
+ err . task = metadata . task ;
34
+ gulp . emit ( 'task_err' , err ) ;
35
+ }
36
+ }
37
+
16
38
const task = program . args [ 0 ] ;
17
39
18
40
if ( ! task ) {
@@ -22,5 +44,5 @@ if (!task) {
22
44
23
45
require ( './gulpfile' ) ;
24
46
25
- gulp . start ( task ) ;
47
+ runTask ( task ) ;
26
48
}
You can’t perform that action at this time.
0 commit comments