diff --git a/index.js b/index.js index 5ad9f1f..b729291 100644 --- a/index.js +++ b/index.js @@ -167,20 +167,15 @@ var NpmtsCompile; return plugins.path.join(paths.cwd, config.ts[key]); } })(); - var tsStream = plugins.gulp.src([plugins.path.join(paths.cwd, key), "!**/typings/**"]) + var stream = plugins.gulp.src([plugins.path.join(paths.cwd, key), "!**/typings/**"]) .pipe(plugins.g.sourcemaps.init()) // This means sourcemaps will be generated .pipe(plugins.g.typescript({ out: outputName, - declaration: true, target: "ES5", module: "commonjs" - })); - var stream = plugins.mergeStream([ - //tsStream.dts.pipe(plugins.gulp.dest(outputDir)), - tsStream.js - .pipe(plugins.g.sourcemaps.write()) // Now the sourcemaps are added to the .js file - .pipe(plugins.gulp.dest(outputDir)) - ]); + })) + .pipe(plugins.g.sourcemaps.write()) // Now the sourcemaps are added to the .js file + .pipe(plugins.gulp.dest(outputDir)); moduleStream.add(stream); } moduleStream.on("queueDrain", function () { diff --git a/package.json b/package.json index 032cf46..7e2106b 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,6 @@ "fs-extra": "^0.26.5", "gulp": "3.9.1", "gulp-coveralls": "^0.1.4", - "gulp-header": "^1.7.1", "gulp-istanbul": "^0.10.3", "gulp-mocha": "^2.2.0", "gulp-sourcemaps": "^1.6.0", diff --git a/test/assets/dist/index.d.ts b/test/assets/dist/index.d.ts deleted file mode 100644 index 0d76e0a..0000000 --- a/test/assets/dist/index.d.ts +++ /dev/null @@ -1,4 +0,0 @@ -/// -declare var testplugin: { - logSomething: () => void; -}; diff --git a/ts/npmts.compile.ts b/ts/npmts.compile.ts index 5f337e0..1b96996 100644 --- a/ts/npmts.compile.ts +++ b/ts/npmts.compile.ts @@ -67,21 +67,16 @@ module NpmtsCompile { } })(); - var tsStream = plugins.gulp.src([plugins.path.join(paths.cwd,key),"!**/typings/**"]) + var stream = plugins.gulp.src([plugins.path.join(paths.cwd,key),"!**/typings/**"]) .pipe(plugins.g.sourcemaps.init()) // This means sourcemaps will be generated .pipe(plugins.g.typescript({ out: outputName, - declaration: true, target: "ES5", module: "commonjs" - })); - var stream = plugins.mergeStream([ - //tsStream.dts.pipe(plugins.gulp.dest(outputDir)), - tsStream.js - .pipe(plugins.g.sourcemaps.write()) // Now the sourcemaps are added to the .js file - //.pipe(plugins.g.header('#!/usr/bin/env node\n\n')) - .pipe(plugins.gulp.dest(outputDir)) - ]); + })) + .pipe(plugins.g.sourcemaps.write()) // Now the sourcemaps are added to the .js file + //.pipe(plugins.g.header('#!/usr/bin/env node\n\n')) + .pipe(plugins.gulp.dest(outputDir)); moduleStream.add(stream); } moduleStream.on("queueDrain",function(){