-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgulpfile.js
43 lines (35 loc) · 1.19 KB
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
const gulp = require('gulp');
const shell = require('gulp-shell');
gulp.task('default', ['deploy']);
gulp.task('build', shell.task([ // gitbook destroys everything in the _book directory!
'gitbook build', // build HTML in _book
],
{ verbose: true }
)
);
gulp.task('deploy', ['build'], shell.task(
[ 'git add . ',
'git ci -am "new version"', // commit changes
'git push origin master' // push changes to gitbook repo
]
)
);
gulp.task('ghrepo', shell.task( // Open a browser in the github book repo
'hub browse etsiiull/gitbook-skeleton'
));
gulp.task('apuntes', shell.task( // Open web browser in the github deployment of this book
'open https://ull-esit-gradoii-tfg.github.io/tfg-ideas/_book/'
));
gulp.task("pre-install", shell.task([ // global dependencies
"npm i -g gitbook-cli",
"brew install hub"
]));
gulp.task("push", shell.task([ // push to github not to gitbook
'git ci -am "new version" && git push origin master',
]));
gulp.task('serve', shell.task([ // gitbook destroys everything in the _book directory!
'gitbook serve', // build HTML in _book
],
{ verbose: true }
)
);