gulp-typescript icon indicating copy to clipboard operation
gulp-typescript copied to clipboard

Emit .buildinfo file

Open michaelaird opened this issue 6 years ago • 6 comments

This is a first step in supporting incremental builds

michaelaird avatar Jun 16 '19 14:06 michaelaird

@ivogabe I can't figure out why these tests are failing. Can you have a look?

michaelaird avatar Jun 17 '19 20:06 michaelaird

@ivogabe I would really like this to be merged. Anything I can assist with?

arieldf avatar Jul 01 '19 19:07 arieldf

I would really like this to be merged as well...

From what I can see, the file "test/tsConfigIncremental/gulptask.js" is triggered for all TS versions, but since there is no tsbuildinfo in versions earlier than 3.4, the tests fail, because earlier TS versions don't just ignore the unknown option, but complain about it instead.

To fix this, one must either strip the unknown option for versions prior to 3.4, or make the test detect 3.4, and skip it if it's earlier. I'm not entirely sure how do either of those things... I'm just pointing out the cause.

For detecting version and skipping tests, I think perhaps if this line is modified to also pass in the version, the test can check it from its start and just return right there.

boenrobot avatar Sep 09 '19 06:09 boenrobot

Hmm... it looks like tsbuildinfo contains full paths, which is why the paths from my PC leaked into the test baseline for this... oops. And I'm not sure what's going on with the other error, but suffice it to say the baseline should probably be adjusted to match the test.

boenrobot avatar Sep 12 '19 20:09 boenrobot

I’ll try to take a look at this in the weekend.

ivogabe avatar Sep 12 '19 20:09 ivogabe

BTW, I tried to actually use this, and there's a problem with it - if the tsconfig.json does not define an outFile, no buildinfo is emitted.

If you use tsc from the command line, you do get it, so this is a bug with this PR or TS as a lib.

boenrobot avatar Sep 13 '19 07:09 boenrobot