fixed bump script
This commit is contained in:
parent
6b8ce0ab4f
commit
accf0dbafb
2
dist
2
dist
@ -1 +1 @@
|
|||||||
Subproject commit f21e1c549a12275c36980fe6d117fa1589f1ff69
|
Subproject commit 5c7bab422f236b5d29f767f8c6b6f0dfef55cfde
|
@ -127,9 +127,8 @@ module.exports = function (gulp, helperOptions) {
|
|||||||
]))
|
]))
|
||||||
})
|
})
|
||||||
|
|
||||||
gulp.task('bump', function () {
|
gulp.task('bump', function (cb) {
|
||||||
var bumptype
|
gulp.src(['./package.json', './bower.json', './dist/bower.json'], {base: '.'})
|
||||||
return gulp.src(['./package.json', './bower.json', './dist/bower.json'], {base: '.'})
|
|
||||||
.pipe($.prompt.prompt({
|
.pipe($.prompt.prompt({
|
||||||
type: 'checkbox',
|
type: 'checkbox',
|
||||||
name: 'bump',
|
name: 'bump',
|
||||||
@ -139,9 +138,29 @@ module.exports = function (gulp, helperOptions) {
|
|||||||
if (res.bump.length === 0) {
|
if (res.bump.length === 0) {
|
||||||
console.info('You have to select a bump type. Now I\'m going to use "patch" as bump type..')
|
console.info('You have to select a bump type. Now I\'m going to use "patch" as bump type..')
|
||||||
}
|
}
|
||||||
bumptype = res.bump[0]
|
var bumptype = res.bump[0]
|
||||||
|
if (bumptype === 'major') {
|
||||||
|
runSequence('bump_major', cb)
|
||||||
|
} else if (bumptype === 'minor') {
|
||||||
|
runSequence('bump_minor', cb)
|
||||||
|
} else {
|
||||||
|
runSequence('bump_patch', cb)
|
||||||
|
}
|
||||||
}))
|
}))
|
||||||
.pipe($.bump({type: bumptype}))
|
})
|
||||||
|
gulp.task('bump_patch', function () {
|
||||||
|
return gulp.src(['./package.json', './bower.json', './dist/bower.json'], {base: '.'})
|
||||||
|
.pipe($.bump({type: 'patch'}))
|
||||||
|
.pipe(gulp.dest('./'))
|
||||||
|
})
|
||||||
|
gulp.task('bump_minor', function () {
|
||||||
|
return gulp.src(['./package.json', './bower.json', './dist/bower.json'], {base: '.'})
|
||||||
|
.pipe($.bump({type: 'minor'}))
|
||||||
|
.pipe(gulp.dest('./'))
|
||||||
|
})
|
||||||
|
gulp.task('bump_major', function () {
|
||||||
|
return gulp.src(['./package.json', './bower.json', './dist/bower.json'], {base: '.'})
|
||||||
|
.pipe($.bump({type: 'major'}))
|
||||||
.pipe(gulp.dest('./'))
|
.pipe(gulp.dest('./'))
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user