From 2bf69ffbafc342b1ab1999a8a43811b6a22d6208 Mon Sep 17 00:00:00 2001 From: jw255 Date: Wed, 10 Jan 2018 10:20:00 +0000 Subject: barebone .ts node server. pushing to see if all dependencies are included and if it runs on the host server --- gulpfile.js | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 gulpfile.js (limited to 'gulpfile.js') diff --git a/gulpfile.js b/gulpfile.js new file mode 100644 index 0000000..7c897ce --- /dev/null +++ b/gulpfile.js @@ -0,0 +1,23 @@ +const gulp = require('gulp'); +const ts = require('gulp-typescript'); +const JSON_FILES = ['src/*.json', 'src/**/*.json']; + +// pull in the project TypeScript config +const tsProject = ts.createProject('tsconfig.json'); + +gulp.task('scripts', () => { + const tsResult = tsProject.src() + .pipe(tsProject()); + return tsResult.js.pipe(gulp.dest('dist')); +}); + +gulp.task('watch', ['scripts'], () => { + gulp.watch('src/**/*.ts', ['scripts']); +}); + +gulp.task('assets', function() { + return gulp.src(JSON_FILES) + .pipe(gulp.dest('dist')); +}); + +gulp.task('default', ['watch', 'assets']); -- cgit v1.2.1