-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support --incremental builds by emitting .buildinfo #611
Comments
NB: unfortunately, setting "incremental", either in tsconfig.json or in the call to gulp-typescript, doesn't work. |
This may need to wait for typescript to provide an API |
If you want to use typescript 3.4 with gulp-typescript on composite builds, then you can trick typescript into not tripping up by explicitly setting tsBuildInfoFile:
I needed to find a way for us as we'd like to keep in step on language features and we can now use incremental in our dev build. |
Unfotunately this didn't work for us. There is still no ".tsBuildInfo" |
You won't be able to get that until this issue is resolve which depends on API support. We're using tsc --build for our developer build and then gulp-typescript for our production bundle. |
The Typescript issue is now closed: microsoft/TypeScript#29978 |
Having support for the --incremental flag would be great. |
Great news that TypeScript now exposes this in an API. I personally won't have time to work on this in the following weeks. If someone wants to work on this, let me know and I'd be happy to give some guidance. I'm not that familiar with the |
I took a first crack at emitting .buildinfo files (#618) . This might be enough? |
@michaelaird does your PR enable the incremental builds only if the option in
or do we need to change something else in the stream? |
If the .buildinfo file is created by tsc ( because the composite option or
incremental option is true) the buildinfo file will be available on
result.buildInfo.
It’s possible we might want to always emit this alongside the js and not
need another stream.
…On Sun, Jun 16, 2019 at 11:09 AM Melih Yıldız ***@***.***> wrote:
@michaelaird <https://github.com/michaelaird> does your PR enable the
incremental builds only if the option in tsconfig.json is set?
"tsBuildInfoFile": "./buildcache/tsBuildInfo",
or do we need to change something else in the stream?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#611?email_source=notifications&email_token=AABVP2OBYS5FL3UBE4QCLSDP2ZJTLA5CNFSM4G7CYPL2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODXZPBYQ#issuecomment-502460642>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AABVP2PURJ2QINICUIXN7TTP2ZJTLANCNFSM4G7CYPLQ>
.
|
Any workaround available? It takes like 5 seconds to build all my scripts, and it takes milliseconds when in incremental mode. |
It's entirely possible that my changes targeting 3.4/3.5 are entirely useless with 3.6 and the correct approach is to tie into the the new apis to support incremental builds (microsoft/TypeScript#31849) , ie createIncrementalCompilerHost and createIncrementalProgram. |
That’s a good point, I’ll try to make some time for it this weekend |
any updates on this? |
There were some issues with the tests, after upgrading TypeScript. I don’t get them locally, so it may be OS related. The tsbuildinfo file can currently crash the compiler, so I was preparing a temporary fix which would just ignore the tsbuildinfo file, and then later implement the new incremental apis. I’ll continue with it in this weekend |
@ivogabe Thank you! Please let me know if i can help. |
Any updates on this? |
Work-in-progress PR in #635. Some functionalities of the new API are not clear to me yet, I hope to get more information on that soon. |
Typescript 3.4 introduces emitting .tsbuildinfo files that are used for --incremental builds outside of --watch: https://devblogs.microsoft.com/typescript/announcing-typescript-3-4-rc/
gulp-typescript should emit the appropriate .tsbuildinfo files.
The text was updated successfully, but these errors were encountered: