2015-09-20 17:21:29 +00:00
|
|
|
// import gulp
|
|
|
|
var gulp = require("gulp"),
|
|
|
|
gulpTypescript = require("gulp-typescript");
|
|
|
|
|
|
|
|
gulp.task('compileTS', function() {
|
|
|
|
var stream = gulp.src('../index.ts')
|
|
|
|
.pipe(gulpTypescript({
|
|
|
|
out: "index.js"
|
|
|
|
}))
|
|
|
|
.pipe(gulp.dest("../../"));
|
|
|
|
return stream;
|
|
|
|
});
|
|
|
|
|
2015-09-26 18:46:16 +00:00
|
|
|
gulp.task('compileTSTest', function() {
|
|
|
|
var stream = gulp.src('../test.ts')
|
|
|
|
.pipe(gulpTypescript({
|
|
|
|
out: "test.js"
|
|
|
|
}))
|
|
|
|
.pipe(gulp.dest("../../"));
|
|
|
|
return stream;
|
|
|
|
});
|
|
|
|
|
|
|
|
gulp.task('default',['compileTS','compileTSTest'], function() {
|
2015-09-20 17:21:29 +00:00
|
|
|
console.log('Typescript compiled');
|
|
|
|
});
|